Project

General

Profile

« Previous | Next » 

Revision 1577

Added by Dietmar over 12 years ago

fixed save dirmode and filmode to 0 if not superadmin

View differences:

branches/2.8.x/CHANGELOG
11 11
! = Update/Change
12 12

  
13 13
=========================== add small Features 2.8.2 ==========================
14
16 Jan-2012 Build 1577 Dietmar Woellbrink (Luisehahne)
15
# fixed save dirmode and filmode to 0 if not superadmin
14 16
16 Jan-2012 Build 1576 Werner v.d.Decken(DarkViper)
15 17
# wysiwyg module changed to domain independend image links
16 18
16 Jan-2012 Build 1575 Dietmar Woellbrink (Luisehahne)
branches/2.8.x/wb/admin/interface/version.php
52 52

  
53 53
// check if defined to avoid errors during installation (redirect to admin panel fails if PHP error/warnings are enabled)
54 54
if(!defined('VERSION')) define('VERSION', '2.8.2');
55
if(!defined('REVISION')) define('REVISION', '1576');
55
if(!defined('REVISION')) define('REVISION', '1577');
56 56
if(!defined('SP')) define('SP', 'SP2');
branches/2.8.x/wb/admin/settings/save.php
81 81
		$dir_mode = STRING_DIR_MODE;
82 82
	}
83 83
} else {
84
	// Work-out the octal value for file mode
85
	$u = 0;
86
	if(isset($_POST['file_u_r']) && $_POST['file_u_r'] == 'true') {
87
		$u = $u+4;
84
	$file_mode = STRING_FILE_MODE;
85
	$dir_mode = STRING_DIR_MODE;
86
	if($admin->get_user_id()=='1')
87
	{
88
		// Work-out the octal value for file mode
89
		$u = 0;
90
		if(isset($_POST['file_u_r']) && $_POST['file_u_r'] == 'true') {
91
			$u = $u+4;
92
		}
93
		if(isset($_POST['file_u_w']) && $_POST['file_u_w'] == 'true') {
94
			$u = $u+2;
95
		}
96
		if(isset($_POST['file_u_e']) && $_POST['file_u_e'] == 'true') {
97
			$u = $u+1;
98
		}
99
		$g = 0;
100
		if(isset($_POST['file_g_r']) && $_POST['file_g_r'] == 'true') {
101
			$g = $g+4;
102
		}
103
		if(isset($_POST['file_g_w']) && $_POST['file_g_w'] == 'true') {
104
			$g = $g+2;
105
		}
106
		if(isset($_POST['file_g_e']) && $_POST['file_g_e'] == 'true') {
107
			$g = $g+1;
108
		}
109
		$o = 0;
110
		if(isset($_POST['file_o_r']) && $_POST['file_o_r'] == 'true') {
111
			$o = $o+4;
112
		}
113
		if(isset($_POST['file_o_w']) && $_POST['file_o_w'] == 'true') {
114
			$o = $o+2;
115
		}
116
		if(isset($_POST['file_o_e']) && $_POST['file_o_e'] == 'true') {
117
			$o = $o+1;
118
		}
119
		$file_mode = "0".$u.$g.$o;
120
		// Work-out the octal value for dir mode
121
		$u = 0;
122
		if(isset($_POST['dir_u_r']) && $_POST['dir_u_r'] == 'true') {
123
			$u = $u+4;
124
		}
125
		if(isset($_POST['dir_u_w']) && $_POST['dir_u_w'] == 'true') {
126
			$u = $u+2;
127
		}
128
		if(isset($_POST['dir_u_e']) && $_POST['dir_u_e'] == 'true') {
129
			$u = $u+1;
130
		}
131
		$g = 0;
132
		if(isset($_POST['dir_g_r']) && $_POST['dir_g_r'] == 'true') {
133
			$g = $g+4;
134
		}
135
		if(isset($_POST['dir_g_w']) && $_POST['dir_g_w'] == 'true') {
136
			$g = $g+2;
137
		}
138
		if(isset($_POST['dir_g_e']) && $_POST['dir_g_e'] == 'true') {
139
			$g = $g+1;
140
		}
141
		$o = 0;
142
		if(isset($_POST['dir_o_r']) && $_POST['dir_o_r'] == 'true') {
143
			$o = $o+4;
144
		}
145
		if(isset($_POST['dir_o_w']) && $_POST['dir_o_w'] == 'true') {
146
			$o = $o+2;
147
		}
148
		if(isset($_POST['dir_o_e']) && $_POST['dir_o_e'] == 'true') {
149
			$o = $o+1;
150
		}
151
		$dir_mode = "0".$u.$g.$o;
88 152
	}
89
	if(isset($_POST['file_u_w']) && $_POST['file_u_w'] == 'true') {
90
		$u = $u+2;
91
	}
92
	if(isset($_POST['file_u_e']) && $_POST['file_u_e'] == 'true') {
93
		$u = $u+1;
94
	}
95
	$g = 0;
96
	if(isset($_POST['file_g_r']) && $_POST['file_g_r'] == 'true') {
97
		$g = $g+4;
98
	}
99
	if(isset($_POST['file_g_w']) && $_POST['file_g_w'] == 'true') {
100
		$g = $g+2;
101
	}
102
	if(isset($_POST['file_g_e']) && $_POST['file_g_e'] == 'true') {
103
		$g = $g+1;
104
	}
105
	$o = 0;
106
	if(isset($_POST['file_o_r']) && $_POST['file_o_r'] == 'true') {
107
		$o = $o+4;
108
	}
109
	if(isset($_POST['file_o_w']) && $_POST['file_o_w'] == 'true') {
110
		$o = $o+2;
111
	}
112
	if(isset($_POST['file_o_e']) && $_POST['file_o_e'] == 'true') {
113
		$o = $o+1;
114
	}
115
	$file_mode = "0".$u.$g.$o;
116
	// Work-out the octal value for dir mode
117
	$u = 0;
118
	if(isset($_POST['dir_u_r']) && $_POST['dir_u_r'] == 'true') {
119
		$u = $u+4;
120
	}
121
	if(isset($_POST['dir_u_w']) && $_POST['dir_u_w'] == 'true') {
122
		$u = $u+2;
123
	}
124
	if(isset($_POST['dir_u_e']) && $_POST['dir_u_e'] == 'true') {
125
		$u = $u+1;
126
	}
127
	$g = 0;
128
	if(isset($_POST['dir_g_r']) && $_POST['dir_g_r'] == 'true') {
129
		$g = $g+4;
130
	}
131
	if(isset($_POST['dir_g_w']) && $_POST['dir_g_w'] == 'true') {
132
		$g = $g+2;
133
	}
134
	if(isset($_POST['dir_g_e']) && $_POST['dir_g_e'] == 'true') {
135
		$g = $g+1;
136
	}
137
	$o = 0;
138
	if(isset($_POST['dir_o_r']) && $_POST['dir_o_r'] == 'true') {
139
		$o = $o+4;
140
	}
141
	if(isset($_POST['dir_o_w']) && $_POST['dir_o_w'] == 'true') {
142
		$o = $o+2;
143
	}
144
	if(isset($_POST['dir_o_e']) && $_POST['dir_o_e'] == 'true') {
145
		$o = $o+1;
146
	}
147
	$dir_mode = "0".$u.$g.$o;
148 153
}
149 154

  
150 155
$allow_tags_in_fields = array('website_header', 'website_footer');

Also available in: Unified diff