aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorfriendica <info@friendica.com>2012-03-16 16:05:16 -0700
committerfriendica <info@friendica.com>2012-03-16 16:05:16 -0700
commit82f2bfea5bbf7c35450eb8fe9ee119e0b00d3d61 (patch)
tree846aacbf5ceb7fc9c97ba4cf3891461f8122cfd1
parent949c6d47b5b9a3e796cdf6dff79d6d532f4a3159 (diff)
downloadvolse-hubzilla-82f2bfea5bbf7c35450eb8fe9ee119e0b00d3d61.tar.gz
volse-hubzilla-82f2bfea5bbf7c35450eb8fe9ee119e0b00d3d61.tar.bz2
volse-hubzilla-82f2bfea5bbf7c35450eb8fe9ee119e0b00d3d61.zip
convert boolean or int settings to strings to work around issues with template processing
-rwxr-xr-xmod/settings.php14
1 files changed, 7 insertions, 7 deletions
diff --git a/mod/settings.php b/mod/settings.php
index f694b5840..3a8ad29d2 100755
--- a/mod/settings.php
+++ b/mod/settings.php
@@ -652,20 +652,20 @@ function settings_content(&$a) {
$blocktags = $a->user['blocktags'];
$expire_items = get_pconfig(local_user(), 'expire','items');
- $expire_items = (($expire_items===false)?1:$expire_items); // default if not set: 1
+ $expire_items = (($expire_items===false)? '1' : $expire_items); // default if not set: 1
$expire_notes = get_pconfig(local_user(), 'expire','notes');
- $expire_notes = (($expire_notes===false)?1:$expire_notes); // default if not set: 1
+ $expire_notes = (($expire_notes===false)? '1' : $expire_notes); // default if not set: 1
$expire_starred = get_pconfig(local_user(), 'expire','starred');
- $expire_starred = (($expire_starred===false)?1:$expire_starred); // default if not set: 1
+ $expire_starred = (($expire_starred===false)? '1' : $expire_starred); // default if not set: 1
$expire_photos = get_pconfig(local_user(), 'expire','photos');
- $expire_photos = (($expire_photos===false)?0:$expire_photos); // default if not set: 0
+ $expire_photos = (($expire_photos===false)? '0' : $expire_photos); // default if not set: 0
$suggestme = get_pconfig(local_user(), 'system','suggestme');
- $suggestme = (($suggestme===false)?0:$suggestme); // default if not set: 0
+ $suggestme = (($suggestme===false)? '0': $suggestme); // default if not set: 0
$browser_update = intval(get_pconfig(local_user(), 'system','update_interval'));
$browser_update = (($browser_update == 0) ? 40 : $browser_update / 1000); // default if not set: 40 seconds
@@ -736,13 +736,13 @@ function settings_content(&$a) {
));
$blockwall = replace_macros($opt_tpl,array(
- '$field' => array('blockwall', t('Allow friends to post to your profile page?'), ! $a->user['blockwall'], '', array(t('No'),t('Yes'))),
+ '$field' => array('blockwall', t('Allow friends to post to your profile page?'), (intval($a->user['blockwall']) ? '0' : '1'), '', array(t('No'),t('Yes'))),
));
$blocktags = replace_macros($opt_tpl,array(
- '$field' => array('blocktags', t('Allow friends to tag your posts?'), ! $a->user['blocktags'], '', array(t('No'),t('Yes'))),
+ '$field' => array('blocktags', t('Allow friends to tag your posts?'), (intval($a->user['blocktags']) ? '0' : '1'), '', array(t('No'),t('Yes'))),
));