summaryrefslogtreecommitdiff
path: root/actions
diff options
context:
space:
mode:
authorZach Copley <zach@controlyourself.ca>2009-01-18 01:31:39 +0000
committerZach Copley <zach@controlyourself.ca>2009-01-18 01:31:39 +0000
commit3e18c2f0f8bbab01e16f66254dc9eadc9e1ffd60 (patch)
treefa42e4e9175f6003b7d57ba64dadeaf1986b412e /actions
parent2c9759c3b329eff455b3998d748292d581635f90 (diff)
trac750 Facebook App - generate HTML similar to uiredisign for everything
Diffstat (limited to 'actions')
-rw-r--r--actions/facebookhome.php10
-rw-r--r--actions/facebookinvite.php8
-rw-r--r--actions/facebooksettings.php14
3 files changed, 17 insertions, 15 deletions
diff --git a/actions/facebookhome.php b/actions/facebookhome.php
index b780b8cc3..46f886451 100644
--- a/actions/facebookhome.php
+++ b/actions/facebookhome.php
@@ -19,7 +19,7 @@
if (!defined('LACONICA')) { exit(1); }
-require_once(INSTALLDIR.'/lib/facebookaction.php');
+require_once INSTALLDIR.'/lib/facebookaction.php';
class FacebookhomeAction extends FacebookAction
{
@@ -35,6 +35,8 @@ class FacebookhomeAction extends FacebookAction
$flink = Foreign_link::getByForeignID($fbuid, FACEBOOK_SERVICE);
if ($flink) {
+ $user = $flink->getUser();
+ common_set_user($user);
$this->showHome($flink, null);
} else {
$this->login($fbuid);
@@ -103,7 +105,7 @@ class FacebookhomeAction extends FacebookAction
update_profile_box($facebook, $fbuid, $user, $notice);
- $this->show_header('Home');
+ $this->showHeader('Home');
if ($msg) {
common_element('fb:success', array('message' => $msg));
@@ -111,7 +113,7 @@ class FacebookhomeAction extends FacebookAction
echo $this->show_notices($user);
- $this->show_footer();
+ $this->showFooter();
}
function show_notices($user)
@@ -132,7 +134,7 @@ class FacebookhomeAction extends FacebookAction
function show_notice_list($notice)
{
- $nl = new NoticeList($notice);
+ $nl = new FacebookNoticeList($notice);
return $nl->show();
}
diff --git a/actions/facebookinvite.php b/actions/facebookinvite.php
index fe0c5e493..d7e82dae7 100644
--- a/actions/facebookinvite.php
+++ b/actions/facebookinvite.php
@@ -41,7 +41,7 @@ class FacebookinviteAction extends FacebookAction
$facebook = get_facebook();
$fbuid = $facebook->require_login();
- $this->show_header('Invite');
+ $this->showHeader('Invite');
common_element('h2', null, _('Thanks for inviting your friends to use Identi.ca!'));
common_element('p', null, _('Invitations have been sent to the following users:'));
@@ -60,7 +60,7 @@ class FacebookinviteAction extends FacebookAction
common_element_end("ul");
- $this->show_footer();
+ $this->showFooter();
}
function showInviteForm()
@@ -69,7 +69,7 @@ class FacebookinviteAction extends FacebookAction
$facebook = get_facebook();
$fbuid = $facebook->require_login();
- $this->show_header('Invite');
+ $this->showHeader('Invite');
// Get a list of users who are already using the app for exclusion
$exclude_ids = $facebook->api_client->friends_getAppUsers();
@@ -104,7 +104,7 @@ class FacebookinviteAction extends FacebookAction
common_element_end("ul");
- $this->show_footer();
+ $this->showFooter();
}
diff --git a/actions/facebooksettings.php b/actions/facebooksettings.php
index ab04ad82b..eafd91123 100644
--- a/actions/facebooksettings.php
+++ b/actions/facebooksettings.php
@@ -19,7 +19,7 @@
if (!defined('LACONICA')) { exit(1); }
-require_once(INSTALLDIR.'/lib/facebookaction.php');
+require_once INSTALLDIR.'/lib/facebookaction.php';
class FacebooksettingsAction extends FacebookAction
{
@@ -29,13 +29,13 @@ class FacebooksettingsAction extends FacebookAction
parent::handle($args);
if ($this->arg('save')) {
- $this->save_settings();
+ $this->saveSettings();
} else {
- $this->show_form();
+ $this->showForm();
}
}
- function save_settings() {
+ function saveSettings() {
$noticesync = $this->arg('noticesync');
$replysync = $this->arg('replysync');
@@ -59,14 +59,14 @@ class FacebooksettingsAction extends FacebookAction
}
}
- function show_form($msg = null, $success = false) {
+ function showForm($msg = null, $success = false) {
$facebook = get_facebook();
$fbuid = $facebook->require_login();
$flink = Foreign_link::getByForeignID($fbuid, FACEBOOK_SERVICE);
- $this->show_header('Settings', $msg, $success);
+ $this->showHeader('Settings', $msg, $success);
common_element_start('fb:if-section-not-added', array('section' => 'profile'));
common_element('h2', null, _('Add an Identi.ca box to my profile'));
@@ -108,7 +108,7 @@ class FacebooksettingsAction extends FacebookAction
}
- $this->show_footer();
+ $this->showFooter();
}
}