diff options
author | Mike Macgirvin <mike@macgirvin.com> | 2010-07-19 19:09:58 -0700 |
---|---|---|
committer | Mike Macgirvin <mike@macgirvin.com> | 2010-07-19 19:09:58 -0700 |
commit | c3fd5ed73202f4dd17dda87ac968b0db4f44d423 (patch) | |
tree | 353a6394ebb8ea8eddd0f8dc862fa7d09a3ee0b1 /mod/profiles.php | |
parent | 6695b4a203ab03941c8b3305a3e55cc02b85a5ac (diff) | |
download | volse-hubzilla-c3fd5ed73202f4dd17dda87ac968b0db4f44d423.tar.gz volse-hubzilla-c3fd5ed73202f4dd17dda87ac968b0db4f44d423.tar.bz2 volse-hubzilla-c3fd5ed73202f4dd17dda87ac968b0db4f44d423.zip |
one true profile photo, force nicknames
Diffstat (limited to 'mod/profiles.php')
-rw-r--r-- | mod/profiles.php | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/mod/profiles.php b/mod/profiles.php index 208f8545e..db4426474 100644 --- a/mod/profiles.php +++ b/mod/profiles.php @@ -4,7 +4,7 @@ function profiles_post(&$a) { if(! local_user()) { - $_SESSION['sysmsg'] .= "Unauthorised." . EOL; + notice( "Permission denied." . EOL); return; } if(($a->argc > 1) && ($a->argv[1] != "new") && intval($a->argv[1])) { @@ -251,9 +251,6 @@ function profiles_content(&$a) { } - - - if(intval($a->argv[1])) { $r = q("SELECT * FROM `profile` WHERE `id` = %d AND `uid` = %d LIMIT 1", intval($a->argv[1]), @@ -265,7 +262,7 @@ function profiles_content(&$a) { } require_once('mod/profile.php'); - profile_load($a,$_SESSION['uid'],$r[0]['id']); + profile_load($a,$a->user['nickname'],$r[0]['id']); require_once('view/profile_selectors.php'); @@ -293,6 +290,7 @@ function profiles_content(&$a) { $is_default = (($r[0]['is-default']) ? 1 : 0); $tpl = file_get_contents("view/profile_edit.tpl"); $o .= replace_macros($tpl,array( + '$disabled' => (($is_default) ? 'onclick="return false;" style="color: #BBBBFF;"' : ''), '$baseurl' => $a->get_baseurl(), '$profile_id' => $r[0]['id'], '$profile_name' => $r[0]['profile-name'], |