diff options
author | brettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2010-03-03 17:53:05 +0000 |
---|---|---|
committer | brettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2010-03-03 17:53:05 +0000 |
commit | 4766f36a4d74924f21ff329c4318ce4e069ffa04 (patch) | |
tree | 969b84632f2a8b0db79788a8a6db8e41d63e5cb4 /mod/twitter/views/default/widgets | |
parent | 57a217fd6b708844407486046a1faa23b46cac08 (diff) | |
download | elgg-4766f36a4d74924f21ff329c4318ce4e069ffa04.tar.gz elgg-4766f36a4d74924f21ff329c4318ce4e069ffa04.tar.bz2 |
Pulled in the interface changes.
git-svn-id: http://code.elgg.org/elgg/trunk@5257 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'mod/twitter/views/default/widgets')
-rw-r--r-- | mod/twitter/views/default/widgets/twitter/edit.php | 20 | ||||
-rw-r--r-- | mod/twitter/views/default/widgets/twitter/view.php | 35 |
2 files changed, 55 insertions, 0 deletions
diff --git a/mod/twitter/views/default/widgets/twitter/edit.php b/mod/twitter/views/default/widgets/twitter/edit.php new file mode 100644 index 000000000..efb8f622a --- /dev/null +++ b/mod/twitter/views/default/widgets/twitter/edit.php @@ -0,0 +1,20 @@ +<?php + + /** + * Elgg twitter edit page + * + * @package ElggTwitter + * @license http://www.gnu.org/licenses/old-licenses/gpl-2.0.html GNU Public License version 2 + * @author Curverider Ltd <info@elgg.com> + * @copyright Curverider Ltd 2008-2010 + * @link http://elgg.com/ + */ + +?> + <p> + <?php echo elgg_echo("twitter:username"); ?> + <input type="text" name="params[twitter_username]" value="<?php echo htmlentities($vars['entity']->twitter_username); ?>" /> + <br /><?php echo elgg_echo("twitter:num"); ?> + <input type="text" name="params[twitter_num]" value="<?php echo htmlentities($vars['entity']->twitter_num); ?>" /> + + </p>
\ No newline at end of file diff --git a/mod/twitter/views/default/widgets/twitter/view.php b/mod/twitter/views/default/widgets/twitter/view.php new file mode 100644 index 000000000..71caaf380 --- /dev/null +++ b/mod/twitter/views/default/widgets/twitter/view.php @@ -0,0 +1,35 @@ +<?php + + /** + * Elgg twitter view page + * + * @package ElggTwitter + * @license http://www.gnu.org/licenses/old-licenses/gpl-2.0.html GNU Public License version 2 + * @author Curverider Ltd <info@elgg.com> + * @copyright Curverider Ltd 2008-2010 + * @link http://elgg.com/ + */ + + //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> +<?php + } else { + + echo "<div class=\"contentWrapper\"><p>" . elgg_echo("twitter:notset") . ".</p></div>"; + + } +?> +</div>
\ No newline at end of file |