aboutsummaryrefslogtreecommitdiff
path: root/mod/twitterservice/views
diff options
context:
space:
mode:
authorbrettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544>2011-03-14 02:06:04 +0000
committerbrettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544>2011-03-14 02:06:04 +0000
commit444611b49a56b2b282d0f9b9290d17aecd9ae321 (patch)
treeaccdc8b21c5b6c3612bad4c78512c5a7b23c9f3a /mod/twitterservice/views
parente62ce5cca46c015629b39c3356bdb5df65f1369e (diff)
downloadelgg-444611b49a56b2b282d0f9b9290d17aecd9ae321.tar.gz
elgg-444611b49a56b2b282d0f9b9290d17aecd9ae321.tar.bz2
Refs #3115. Migrated twitterservice to twitter_api. Added upgrade to migrate plugin and user settings.
git-svn-id: http://code.elgg.org/elgg/trunk@8699 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'mod/twitterservice/views')
-rw-r--r--mod/twitterservice/views/default/settings/twitterservice/edit.php49
-rw-r--r--mod/twitterservice/views/default/twitterservice/css.php12
-rw-r--r--mod/twitterservice/views/default/twitterservice/login.php17
-rw-r--r--mod/twitterservice/views/default/twitterservice/metatags.php19
-rw-r--r--mod/twitterservice/views/default/usersettings/twitterservice/edit.php22
5 files changed, 0 insertions, 119 deletions
diff --git a/mod/twitterservice/views/default/settings/twitterservice/edit.php b/mod/twitterservice/views/default/settings/twitterservice/edit.php
deleted file mode 100644
index 1e7dc1edd..000000000
--- a/mod/twitterservice/views/default/settings/twitterservice/edit.php
+++ /dev/null
@@ -1,49 +0,0 @@
-<?php
-/**
- *
- */
-$insert_view = elgg_view('twittersettings/extend');
-
-$consumer_key_string = elgg_echo('twitterservice:consumer_key');
-$consumer_key_view = elgg_view('input/text', array(
- 'name' => 'params[consumer_key]',
- 'value' => $vars['entity']->consumer_key,
- 'class' => 'text_input',
-));
-
-$consumer_secret_string = elgg_echo('twitterservice:consumer_secret');
-$consumer_secret_view = elgg_view('input/text', array(
- 'name' => 'params[consumer_secret]',
- 'value' => $vars['entity']->consumer_secret,
- 'class' => 'text_input',
-));
-
-$sign_on_with_twitter_string = elgg_echo('twitterservice:login');
-$sign_on_with_twitter_view = elgg_view('input/dropdown', array(
- 'name' => 'params[sign_on]',
- 'options_values' => array(
- 'yes' => elgg_echo('option:yes'),
- 'no' => elgg_echo('option:no'),
- ),
- 'value' => $vars['entity']->sign_on ? $vars['entity']->sign_on : 'no',
-));
-
-$new_users_with_twitter = elgg_echo('twitterservice:new_users');
-$new_users_with_twitter_view = elgg_view('input/dropdown', array(
- 'name' => 'params[new_users]',
- 'options_values' => array(
- 'yes' => elgg_echo('option:yes'),
- 'no' => elgg_echo('option:no'),
- ),
- 'value' => $vars['entity']->new_users ? $vars['entity']->new_users : 'no',
-));
-
-$settings = <<<__HTML
-<div>$insert_view</div>
-<div>$consumer_key_string $consumer_key_view</div>
-<div>$consumer_secret_string $consumer_secret_view</div>
-<div>$sign_on_with_twitter_string $sign_on_with_twitter_view</div>
-<div>$new_users_with_twitter $new_users_with_twitter_view</div>
-__HTML;
-
-echo $settings;
diff --git a/mod/twitterservice/views/default/twitterservice/css.php b/mod/twitterservice/views/default/twitterservice/css.php
deleted file mode 100644
index 572144067..000000000
--- a/mod/twitterservice/views/default/twitterservice/css.php
+++ /dev/null
@@ -1,12 +0,0 @@
-<?php
-/**
- * Elgg TwitterService CSS
- */
-?>
-
-#twitterservice_site_settings .text_input {
- width: 350px;
-}
-#login_with_twitter {
- padding: 10px 0 0 0;
-}
diff --git a/mod/twitterservice/views/default/twitterservice/login.php b/mod/twitterservice/views/default/twitterservice/login.php
deleted file mode 100644
index d4bc04150..000000000
--- a/mod/twitterservice/views/default/twitterservice/login.php
+++ /dev/null
@@ -1,17 +0,0 @@
-<?php
-/**
- *
- */
-
-$url = elgg_get_site_url() . 'twitterservice/forward';
-$img_url = elgg_get_site_url() . 'mod/twitterservice/graphics/sign_in_with_twitter.gif';
-
-$login = <<<__HTML
-<div id="login_with_twitter">
- <a href="$url">
- <img src="$img_url" alt="Twitter" />
- </a>
-</div>
-__HTML;
-
-echo $login;
diff --git a/mod/twitterservice/views/default/twitterservice/metatags.php b/mod/twitterservice/views/default/twitterservice/metatags.php
deleted file mode 100644
index 64c9910fb..000000000
--- a/mod/twitterservice/views/default/twitterservice/metatags.php
+++ /dev/null
@@ -1,19 +0,0 @@
-<?php
-/**
- * Adds required HTML head tags for Twitter Services.
- *
- * @package TwitterService
- */
-
-if ($api_key = elgg_get_plugin_setting('consumer_key', 'twitterservice')) {
- $tags = <<<__HTML
-<script src="http://platform.twitter.com/anywhere.js?id=$api_key&v=1" type="text/javascript"></script>
-<script type="text/javascript">
- twttr.anywhere(function (T) {
- T(".twitter_anywhere").hovercards();
- });
-</script>
-__HTML;
-
- echo $tags;
-}
diff --git a/mod/twitterservice/views/default/usersettings/twitterservice/edit.php b/mod/twitterservice/views/default/usersettings/twitterservice/edit.php
deleted file mode 100644
index 2a5ef8b05..000000000
--- a/mod/twitterservice/views/default/usersettings/twitterservice/edit.php
+++ /dev/null
@@ -1,22 +0,0 @@
-<?php
-/**
- *
- */
-
-$user_id = elgg_get_logged_in_user_guid();
-$twitter_name = get_plugin_usersetting('twitter_name', $user_id, 'twitterservice');
-$access_key = get_plugin_usersetting('access_key', $user_id, 'twitterservice');
-$access_secret = get_plugin_usersetting('access_secret', $user_id, 'twitterservice');
-
-$site_name = elgg_get_site_entity()->name;
-echo '<div>' . elgg_echo('twitterservice:usersettings:description', array($site_name)) . '</div>';
-
-if (!$access_key || !$access_secret) {
- // send user off to validate account
- $request_link = twitterservice_get_authorize_url();
- echo '<div>' . elgg_echo('twitterservice:usersettings:request', array($request_link, $site_name)) . '</div>';
-} else {
- $url = elgg_get_site_url() . "twitterservice/revoke";
- echo '<div class="twitter_anywhere">' . elgg_echo('twitterservice:usersettings:authorized', array($site_name, $twitter_name)) . '</div>';
- echo '<div>' . sprintf(elgg_echo('twitterservice:usersettings:revoke'), $url) . '</div>';
-}