--- a/web/tweetwall.php Tue Jun 18 17:03:11 2013 +0200
+++ b/web/tweetwall.php Tue Jun 18 18:30:16 2013 +0200
@@ -40,11 +40,19 @@
<script type="text/javascript" src="<?php echo(registry_url('raphael','js'))?>"></script>
<script type="text/javascript">
- <?php if (isset($config['hashtag'])) echo "var tracking_keywords = ".json_encode(array($config['hashtag'])).";"; ?>
+ <?php
+ if (isset($config['tracking_keywords']) && count($config['tracking_keywords'])) {
+ echo "var tracking_keywords = ".json_encode($config['tracking_keywords']).';';
+ } elseif (isset($config['hashtag'])) {
+ echo "var tracking_keywords = ".json_encode(array($config['hashtag'])).";";
+ }
+ ?>
<?php if (isset($config['js_config'])) echo $config['js_config']; ?>
</script>
+ <?php if (isset($_SESSION['TWITTER_ACCESS_TOKEN'])) { ?>
<script type="text/javascript" src="<?php echo(registry_url('twcx-main','js'))?>"></script>
+ <?php } ?>
<script type="text/javascript">
@@ -63,7 +71,6 @@
</head>
<body class="tweetwall">
- <div id="sendUsFeedBack"><a href="<?php echo($C_feedback_form_url); ?>" target="_blank"><img src="<?php echo(URL_ROOT); ?>images/sendusfeedback.png"></a></div>
<div id="container">
@@ -85,6 +92,8 @@
</form>
</div>
+ <?php if (isset($_SESSION['TWITTER_ACCESS_TOKEN'])) { ?>
+
<div id="tweetviz">
<ul id="tweetlist"></ul>
<div id="timeline"></div>
@@ -92,6 +101,12 @@
<div id="scrollin"></div>
</div>
</div>
+
+ <?php } else {?>
+
+ <p class="connect-message"><a href="<?php echo URL_ROOT.$rep; ?>/client.php?CONNECT=true"><?php echo $translate->_('You must be connected with your Twitter account to read the conversation'); ?></a></p>
+
+ <?php } ?>
</div>
</div>
<!-- <div id="hovertweet">