diff options
author | cash <cash@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2010-12-01 00:57:18 +0000 |
---|---|---|
committer | cash <cash@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2010-12-01 00:57:18 +0000 |
commit | ad6e04d0bbf812dfe048f1fdbde7aa5c787b6d1a (patch) | |
tree | 31318b4d53199abede8b03a47b1ff79add545ea3 /mod/twitter/views/default/widgets/twitter/content.php | |
parent | 3bda294ee00663362db778fef320f866bc3a28e5 (diff) | |
download | elgg-ad6e04d0bbf812dfe048f1fdbde7aa5c787b6d1a.tar.gz elgg-ad6e04d0bbf812dfe048f1fdbde7aa5c787b6d1a.tar.bz2 |
Fixes #2555 content.php is the new display view for widgets
git-svn-id: http://code.elgg.org/elgg/trunk@7484 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'mod/twitter/views/default/widgets/twitter/content.php')
-rw-r--r-- | mod/twitter/views/default/widgets/twitter/content.php | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/mod/twitter/views/default/widgets/twitter/content.php b/mod/twitter/views/default/widgets/twitter/content.php new file mode 100644 index 000000000..e429d0103 --- /dev/null +++ b/mod/twitter/views/default/widgets/twitter/content.php @@ -0,0 +1,31 @@ +<?php + +/** + * Elgg twitter view page + * + * @package ElggTwitter + */ + +//some required params + +$username = $vars['entity']->twitter_username; +$num = $vars['entity']->twitter_num; + +// if the twitter username is empty, then do not show +if ($username) { + +?> + +<div id="twitter_widget"> + <ul id="twitter_update_list"></ul> + <p class="visit_twitter"><a href="http://twitter.com/<?php echo $username; ?>"><?php echo elgg_echo("twitter:visit"); ?></a></p> + <script type="text/javascript" src="http://twitter.com/javascripts/blogger.js"></script> + <script type="text/javascript" src="http://twitter.com/statuses/user_timeline/<?php echo $username; ?>.json?callback=twitterCallback2&count=<?php echo $num; ?>"></script> +</div> + +<?php +} else { + + echo "<p>" . elgg_echo("twitter:notset") . ".</p>"; + +} |