From a0d6d3c7f9bf3de97fcf9544631eca45ca2d4cb3 Mon Sep 17 00:00:00 2001 From: zottel Date: Fri, 17 Jan 2014 07:56:34 +0100 Subject: [PATCH 1/5] set jsAvailable cookie expire time to match PHPSESSID's --- include/session.php | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/include/session.php b/include/session.php index 6072bdb33..be1ec5ee7 100644 --- a/include/session.php +++ b/include/session.php @@ -15,6 +15,15 @@ function new_cookie($time) { session_regenerate_id(false); q("UPDATE session SET sid = '%s' WHERE sid = '%s'", dbesc(session_id()), dbesc($old_sid)); + + if (x($_COOKIE, 'jsAvailable')) { + if ($time) { + $expires = time() + $time; + } else { + $expires = 0; + } + setcookie('jsAvailable', $_COOKIE['jsAvailable'], $expires); + } } From 1a76f1c65952af16be6f00cde9317b817028f1b6 Mon Sep 17 00:00:00 2001 From: Thomas Willingham Date: Fri, 17 Jan 2014 20:52:57 +0000 Subject: [PATCH 2/5] Un-break dav auth. --- include/reddav.php | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/include/reddav.php b/include/reddav.php index c53838297..838ead7b7 100644 --- a/include/reddav.php +++ b/include/reddav.php @@ -101,8 +101,9 @@ class RedDirectory extends DAV\Node implements DAV\ICollection { $c = q("select * from channel where channel_id = %d and not (channel_pageflags & %d) limit 1", - intval(PAGE_REMOVED), - intval($this->auth->owner_id) + intval($this->auth->owner_id), + intval(PAGE_REMOVED) + ); if(! $c) { @@ -988,4 +989,4 @@ class RedBrowser extends DAV\Browser\Plugin { } -} \ No newline at end of file +} From a59b7c97f45d0c17e925284a42e2610d734f1a24 Mon Sep 17 00:00:00 2001 From: Thomas Willingham Date: Fri, 17 Jan 2014 23:30:33 +0000 Subject: [PATCH 3/5] Missed these from git add...a year ago --- include/identity.php | 2 ++ view/tpl/profile_advanced.tpl | 7 +++++++ 2 files changed, 9 insertions(+) diff --git a/include/identity.php b/include/identity.php index 40a38808b..a99474d42 100644 --- a/include/identity.php +++ b/include/identity.php @@ -952,6 +952,8 @@ function advanced_profile(&$a) { if($txt = prepare_text($a->profile['contact'])) $profile['contact'] = array( t('Contact information and Social Networks:'), $txt); + if($txt = prepare_text($a->profile['channels'])) $profile['channels'] = array( t('My other channels:'), $txt); + if($txt = prepare_text($a->profile['music'])) $profile['music'] = array( t('Musical interests:'), $txt); if($txt = prepare_text($a->profile['book'])) $profile['book'] = array( t('Books, literature:'), $txt); diff --git a/view/tpl/profile_advanced.tpl b/view/tpl/profile_advanced.tpl index 9f17a0ffa..f25608430 100755 --- a/view/tpl/profile_advanced.tpl +++ b/view/tpl/profile_advanced.tpl @@ -111,6 +111,13 @@ {{/if}} +{{if $profile.channels}} +
+
{{$profile.channels.0}}
+
{{$profile.channels.1}}
+
+{{/if}} + {{if $profile.music}}
From 52d52a6a4f22eb1e478f93c75d75378ccb6bc30a Mon Sep 17 00:00:00 2001 From: Thomas Willingham Date: Sat, 18 Jan 2014 05:24:51 +0000 Subject: [PATCH 4/5] Doco - s/chown/chmod --- doc/Install.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/doc/Install.md b/doc/Install.md index 389c9d632..2df82b181 100644 --- a/doc/Install.md +++ b/doc/Install.md @@ -47,7 +47,7 @@ you might have trouble getting everything to work.] `mkdir view/tpl/smarty3` - `chown 777 view/smarty3` + `chmod 777 view/smarty3` - For installing addons @@ -102,4 +102,4 @@ one shown, substituting for your unique paths and settings: You can generally find the location of PHP by executing "which php". If you have troubles with this section please contact your hosting provider for -assistance. Red will not work correctly if you cannot perform this step. \ No newline at end of file +assistance. Red will not work correctly if you cannot perform this step. From 331609cb871517bd35416669492488a3bc14702d Mon Sep 17 00:00:00 2001 From: Thomas Willingham Date: Sat, 18 Jan 2014 18:38:53 +0000 Subject: [PATCH 5/5] vcard widget needs to include Contact if it's not included from the module that calls it. --- include/widgets.php | 1 + 1 file changed, 1 insertion(+) diff --git a/include/widgets.php b/include/widgets.php index a1ff756ff..efa350785 100644 --- a/include/widgets.php +++ b/include/widgets.php @@ -549,6 +549,7 @@ function widget_photo_albums($arr) { function widget_vcard($arr) { + require_once ('include/Contact.php'); return vcard_from_xchan('',get_app()->get_observer()); }