Subversion Repositories Applications.papyrus

Rev

Go to most recent revision | Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
831 florian 1
<?php
2
 
3
////////////////////////////////////////////////////////////////////////////////
4
//                                                                            //
5
//   Copyright (C) 2006  Phorum Development Team                              //
6
//   http://www.phorum.org                                                    //
7
//                                                                            //
8
//   This program is free software. You can redistribute it and/or modify     //
9
//   it under the terms of either the current Phorum License (viewable at     //
10
//   phorum.org) or the Phorum License that was distributed with this file    //
11
//                                                                            //
12
//   This program is distributed in the hope that it will be useful,          //
13
//   but WITHOUT ANY WARRANTY, without even the implied warranty of           //
14
//   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.                     //
15
//                                                                            //
16
//   You should have received a copy of the Phorum License                    //
17
//   along with this program.                                                 //
18
////////////////////////////////////////////////////////////////////////////////
19
 
20
if(!defined("PHORUM_CONTROL_CENTER")) return;
21
 
22
if(count($_POST)) {
23
 
24
    // these two are flipped as we store if hidden in the db, but we ask if allowed in the UI
25
    $_POST["hide_email"] = (isset($_POST["hide_email"]) && $_POST["hide_email"]) ? 0 : 1;
26
    $_POST["hide_activity"] = (isset($_POST["hide_activity"]) && $_POST["hide_activity"]) ? 0 : 1;
27
 
28
    list($error,$okmsg) = phorum_controlcenter_user_save($panel);
29
}
30
 
31
 
32
// these two are flipped as we store if hidden in the db, but we ask if allowed in the UI
33
 
34
if (!empty($PHORUM['DATA']['PROFILE']["hide_email"])) {
35
    $PHORUM["DATA"]["PROFILE"]["hide_email_checked"] = "";
36
} else {
37
    // more html stuff in the code. yuck.
38
    $PHORUM["DATA"]["PROFILE"]["hide_email_checked"] = " checked=\"checked\"";
39
}
40
 
41
if (!empty($PHORUM['DATA']['PROFILE']["hide_activity"])) {
42
    $PHORUM["DATA"]["PROFILE"]["hide_activity_checked"] = "";
43
} else {
44
    // more html stuff in the code. yuck.
45
    $PHORUM["DATA"]["PROFILE"]["hide_activity_checked"] = " checked=\"checked\"";
46
}
47
 
48
$PHORUM["DATA"]["PROFILE"]["block_title"] = $PHORUM["DATA"]["LANG"]["EditPrivacy"];
49
 
50
$PHORUM['DATA']['PROFILE']['PRIVACYSETTINGS'] = 1;
51
$template = "cc_usersettings";
52
 
53
?>