diff options
author | Friendika <info@friendika.com> | 2011-03-20 17:54:50 -0700 |
---|---|---|
committer | Friendika <info@friendika.com> | 2011-03-20 17:54:50 -0700 |
commit | b7292bc673bc7983b1fd933070bc9d6a0a155dbb (patch) | |
tree | f0add46f5b1aa1794a0c40b58069626e96fed4a1 /mod/settings.php | |
parent | 2b0af1456ceebb6be24768d14702742e73125588 (diff) | |
download | volse-hubzilla-b7292bc673bc7983b1fd933070bc9d6a0a155dbb.tar.gz volse-hubzilla-b7292bc673bc7983b1fd933070bc9d6a0a155dbb.tar.bz2 volse-hubzilla-b7292bc673bc7983b1fd933070bc9d6a0a155dbb.zip |
user pref -> block remote wall posting
Diffstat (limited to 'mod/settings.php')
-rw-r--r-- | mod/settings.php | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/mod/settings.php b/mod/settings.php index 85029b3d7..6a2733d7c 100644 --- a/mod/settings.php +++ b/mod/settings.php @@ -70,6 +70,7 @@ function settings_post(&$a) { $net_publish = (((x($_POST,'profile_in_netdirectory')) && (intval($_POST['profile_in_netdirectory']) == 1)) ? 1: 0); $old_visibility = (((x($_POST,'visibility')) && (intval($_POST['visibility']) == 1)) ? 1 : 0); $page_flags = (((x($_POST,'page-flags')) && (intval($_POST['page-flags']))) ? intval($_POST['page-flags']) : 0); + $blockwall = (((x($_POST,'blockwall')) && (intval($_POST['blockwall']) == 1)) ? 0: 1); // this setting is inverted! $notify = 0; @@ -140,7 +141,7 @@ function settings_post(&$a) { $openidserver = ''; } - $r = q("UPDATE `user` SET `username` = '%s', `email` = '%s', `openid` = '%s', `timezone` = '%s', `allow_cid` = '%s', `allow_gid` = '%s', `deny_cid` = '%s', `deny_gid` = '%s', `notify-flags` = %d, `page-flags` = %d, `default-location` = '%s', `allow_location` = %d, `theme` = '%s', `maxreq` = %d, `expire` = %d, `openidserver` = '%s' WHERE `uid` = %d LIMIT 1", + $r = q("UPDATE `user` SET `username` = '%s', `email` = '%s', `openid` = '%s', `timezone` = '%s', `allow_cid` = '%s', `allow_gid` = '%s', `deny_cid` = '%s', `deny_gid` = '%s', `notify-flags` = %d, `page-flags` = %d, `default-location` = '%s', `allow_location` = %d, `theme` = '%s', `maxreq` = %d, `expire` = %d, `openidserver` = '%s', `blockwall` = %d WHERE `uid` = %d LIMIT 1", dbesc($username), dbesc($email), dbesc($openid), @@ -157,6 +158,7 @@ function settings_post(&$a) { intval($maxreq), intval($expire), dbesc($openidserver), + intval($blockwall), intval(local_user()) ); if($r) @@ -241,6 +243,7 @@ function settings_content(&$a) { $openid = $a->user['openid']; $maxreq = $a->user['maxreq']; $expire = ((intval($a->user['expire'])) ? $a->user['expire'] : ''); + $blockwall = $a->user['blockwall']; if(! strlen($a->user['timezone'])) $timezone = date_default_timezone_get(); @@ -362,6 +365,7 @@ function settings_content(&$a) { '$sel_notify5' => (($notify & NOTIFY_MAIL) ? ' checked="checked" ' : ''), '$maxreq' => $maxreq, '$expire' => $expire, + '$blockw_checked' => (($blockwall) ? '' : ' checked="checked" ' ), '$theme' => $theme_selector, '$pagetype' => $pagetype )); |