2 error_reporting(E_COMPILE_ERROR|E_ERROR|E_CORE_ERROR
);
3 define('LANG_FILE','edp.php');
4 $local_user='ck_edv_user';
5 require_once($root_path.'include/inc_front_chain_lang.php');
7 require_once($root_path.'include/inc_config_color.php');
10 * The following require loads the access areas that can be assigned for
13 require($root_path.'include/inc_accessplan_areas_functions.php');
15 $breakfile="edv.php?sid=".$sid."&lang=".$lang;
19 <!DOCTYPE HTML
PUBLIC "-//IETF//DTD HTML 3.0//EN" "html.dtd">
21 <?php
html_rtl($lang); ?
>
23 <?php
echo setCharSet(); ?
>
25 require($root_path.'include/inc_css_a_hilitebu.php');
27 <script language
="javascript">
30 function gethelp(x
,s
,x1
,x2
,x3
)
33 urlholder
="<?php echo $root_path; ?>help-router.php<?php echo URL_REDIRECT_APPEND ?>&helpidx="+x+
"&src="+s+
"&x1="+x1+
"&x2="+x2+
"&x3="+x3
;
34 helpwin
=window
.open(urlholder
,"helpwin","width=790,height=540,menubar=no,resizable=yes,scrollbars=yes");
35 window
.helpwin
.moveTo(0,0);
41 <BODY topmargin
=0 leftmargin
=0 marginheight
=0 marginwidth
=0 bgcolor
=<?php
echo $cfg['bot_bgcolor']?
>>
44 <table width
=100% border
=0 cellspacing
=0 >
46 <td bgcolor
="<?php echo $cfg['top_bgcolor']; ?>" height
="45"><FONT COLOR
="<?php echo $cfg['top_txtcolor']; ?>" SIZE
=+
2 FACE
="Arial">
47 <STRONG
>  
; <?php
echo "$LDEDP $LDUpdateRight" ?
></STRONG
></FONT
></td
>
48 <td bgcolor
="<?php echo $cfg['top_bgcolor']; ?>" height
="10" align
=right
>
49 <?php
if($cfg['dhtml'])echo'<a href="javascript:window.history.back()"><img '.createLDImgSrc($root_path,'back2.gif','0').' style=filter:alpha(opacity=70) onMouseover=hilite(this,1) onMouseOut=hilite(this,0)>';?
></a
><a href
="javascript:gethelp('edp.php','access','update')"><img
<?php
echo createLDImgSrc($root_path,'hilfe-r.gif','0') ?
> <?php
if($cfg['dhtml'])echo'style=filter:alpha(opacity=70) onMouseover=hilite(this,1) onMouseOut=hilite(this,0)>';?
></a
><a href
="<?php echo $breakfile;?>"><img
<?php
echo createLDImgSrc($root_path,'close2.gif','0') ?
> alt
="<?php echo $LDClose ?>" <?php
if($cfg['dhtml'])echo'style=filter:alpha(opacity=70) onMouseover=hilite(this,1) onMouseOut=hilite(this,0)>';?
></a
></td
>
51 <tr bgcolor
="<?php echo $cfg['body_bgcolor']?>">
55 // initialize error flags
64 $curdate=date('Y-m-d');
65 $curtime=date('H:i:s');
67 /* Establish db connection */
68 if(!isset($db)||
!$db) include($root_path.'include/inc_db_makelink.php');
75 $username=trim(strtr($username,"+"," "));
76 $userid=trim($userid);
79 // start checking input data for errors
80 if ($username==""){ $error=1; $errorname=1;};
81 if ($userid==""){$error=1; $erroruser=1;};
82 if ($pass==""){$error=1; $errorpass=1;};
83 if (($bereich1=="")and($bereich2=="")and($bereich3=="")and
84 ($bereich4=="")and($bereich5=="")and($bereich6=="")and($bereich7==""))
85 { $error=1; $errorbereich=1;};
89 echo "<table bgcolor=#dddddd border=1 cellpadding=10 cellspacing=1>
91 <td colspan=3><FONT SIZE=-1 FACE=Arial>";
93 //include('../include/inc_db_makelink.php');
95 $sql='UPDATE care_users SET
96 login_id="'.$userid.'",
98 area1="'.$bereich1.'",
99 area2="'.$bereich2.'",
100 area3="'.$bereich3.'",
101 area4="'.$bereich4.'",
102 area5="'.$bereich5.'",
103 area6="'.$bereich6.'",
104 area7="'.$bereich7.'",
105 area8="'.$bereich8.'",
106 area9="'.$bereich9.'",
107 area10="'.$bereich10.'",
108 s_date="'.$curdate.'",
109 s_time="'.$curtime.'",
110 modify_id="'.$HTTP_COOKIE_VARS[$local_user.$sid].'"
111 WHERE name="'.$username.'"';
113 if($db->Execute($sql))
115 echo mysql_affected_rows()." $LDDataSaved <p>";
116 echo $LDAccessIndex[0].": ".$username."<br>";
117 echo $LDAccessIndex[1].": ".$userid."<br>";
118 echo $LDAccessIndex[2].": ".$pass."<br>";
119 echo $LDAccessIndex[4].": <br>";
120 if($bereich1!="") echo "$LDArea 1: ".$bereich1."<br>";
121 if($bereich2!="") echo "$LDArea 2: ".$bereich2."<br>";
122 if($bereich3!="") echo "$LDArea 3: ".$bereich3."<br>";
123 if($bereich4!="") echo "$LDArea 4: ".$bereich4."<br>";
124 if($bereich5!="") echo "$LDArea 5: ".$bereich5."<br>";
125 if($bereich6!="") echo "$LDArea 6: ".$bereich6."<br>";
126 if($bereich7!="") echo "$LDArea 7: ".$bereich7."<br>";
127 if($bereich8!="") echo "$LDArea 8: ".$bereich8."<br>";
128 if($bereich9!="") echo "$LDArea 9: ".$bereich9."<br>";
129 if($bereich10!="") echo "$LDArea 10: ".$bereich10."<br>";
132 else { echo "$LDDbNoSave<br>$sql"; }
137 <FONT SIZE=-1 FACE=Arial>
139 <FORM method="get" action="edv_user_access_edit.php">
140 <input type="hidden" name="sid" value="'.$sid.'">
141 <input type="hidden" name="lang" value="'.$lang.'">
142 <INPUT type="submit" value="'.$LDOK.'"></font></FORM>
144 <FORM method="get" action="edv_user_access_list.php">
145 <input type="hidden" name="sid" value="'.$sid.'">
146 <input type="hidden" name=lang value="'.$lang.'">
147 <INPUT type="submit" value="'.$LDListActual.'"></font></FORM>
156 $sql='SELECT * FROM care_users WHERE login_id="'.$itemname.'"';
157 $ergebnis=$db->Execute($sql);
160 $zeile=$ergebnis->FetchRow();
161 $username=$zeile['name'];
164 $userid=$zeile['login_id'];
165 $pass=$zeile['password'];
166 $bereich1=$zeile['area1'];
167 $bereich2=$zeile['area2'];
168 $bereich3=$zeile['area3'];
169 $bereich4=$zeile['area4'];
170 $bereich5=$zeile['area5'];
171 $bereich6=$zeile['area6'];
172 $bereich7=$zeile['area7'];
173 $bereich8=$zeile['area8'];
174 $bereich9=$zeile['area9'];
175 $bereich10=$zeile['area10'];
180 else { echo "$LDDbNoLink<br>$sql"; }
187 echo "<FONT COLOR=red SIZE=+1 FACE=Arial>$LDInputError<p>";
193 <?php
if ((($error==1)and($mode=='save'))or(($error==0)and($mode==""))) :; ?
>
195 <form method
="post" action
="edv_user_access_update.php">
196 <table border
=0 cellpadding
=0 cellspacing
=0 bgcolor
=#666666>
199 <table border
="0" cellpadding
="5" cellspacing
="1">
200 <tr bgcolor
="#dddddd">
203 <FONT SIZE
=-1 FACE
="Arial" color
=#000080>
204 <?php
echo $LDName ?
>:
209 echo "<input type=hidden name=username value=".strtr($username," ","+").">";
214 <td
><FONT SIZE
=-1 FACE
="Arial" color
=#000080>
215 <?php
if ($erroruser) {echo "<font color=red > <b>$LDUserId</b>";}
216 else { echo $LDUserId;} ?
>
218 <input type
=text name
=userid
219 <?php
if ($userid!="") echo "value=".$userid ; ?
>
222 <td
><FONT SIZE
=-1 FACE
="Arial" color
=#000080>
223 <?php
if ($errorpass) {echo "<font color=red > <b>$LDPassword</b>";}
224 else { echo $LDPassword;} ?
>
226 <input type
=text name
=pass
227 <?php
if ($pass!="") echo "value=".$pass ; ?
>
231 <tr bgcolor
="#dddddd">
232 <td colspan
=3><FONT SIZE
=-1 FACE
="Arial" color
=#000080>
233 <?php
if ($errorbereich) {echo "<font color=red > <b>$LDAllowedArea</b> </font>";}
234 else { echo $LDAllowedArea;} ?
>
237 <tr bgcolor
="#dddddd">
238 <td valign
=top
><FONT SIZE
=-1 FACE
="Arial" color
=#000080>
240 <?php
echo $LDArea ?
> 1:
241 <select name
=bereich1 size
=1>
242 <?php
createselecttable($bereich1) ?
>
245 <?php
echo $LDArea ?
> 2:
246 <select name
=bereich2 size
=1>
247 <?php
createselecttable($bereich2) ?
>
250 <?php
echo $LDArea ?
> 3:
251 <select name
=bereich3 size
=1>
252 <?php
createselecttable($bereich3) ?
>
255 <?php
echo $LDArea ?
> 4:
256 <select name
=bereich4 size
=1>
257 <?php
createselecttable($bereich4) ?
>
260 <?php
echo $LDArea ?
> 5:
261 <select name
=bereich5 size
=1>
262 <?php
createselecttable($bereich5) ?
>
266 <td valign
=top
><FONT SIZE
=-1 FACE
="Arial" color
=#000080>
268 <?php
echo $LDArea ?
> 6:
269 <select name
=bereich6 size
=1>
270 <?php
createselecttable($bereich6) ?
>
273 <?php
echo $LDArea ?
> 7:
274 <select name
=bereich7 size
=1>
275 <?php
createselecttable($bereich7) ?
>
278 <?php
echo $LDArea ?
> 8:
279 <select name
=bereich8 size
=1>
280 <?php
createselecttable($bereich8) ?
>
283 <?php
echo $LDArea ?
> 9:
284 <select name
=bereich9 size
=1>
285 <?php
createselecttable($bereich9) ?
>
288 <?php
echo $LDArea ?
> 10:
289 <select name
=bereich10 size
=1>
290 <?php
createselecttable($bereich10) ?
>
294 <td valign
="top"><FONT SIZE
=1 FACE
="verdana,Arial">
295 <font color
=#000080 size=2><?php echo $LDAllowedArea ?>:</font><p>
299 * The following line calls the function contained in inc_accessplan_areas_functions.php
306 <tr bgcolor
="#dddddd">
307 <td colspan
=3><FONT SIZE
=-1 FACE
="Arial">
309 <input type
="hidden" name
="itemname" value
="<?php echo $itemname ?>">
310 <input type
="hidden" name
="sid" value
="<?php echo $sid; ?>">
311 <input type
="hidden" name
="lang" value
="<?php echo $lang; ?>">
312 <input type
="hidden" name
="mode" value
="save">
313 <input type
="submit" value
="<?php echo $LDSave ?>">  
;
314 <input type
="reset" value
="<?php echo $LDReset ?>">
324 <FORM method
=get action
="edv_user_access_list.php" >
325 <input type
="hidden" name
="sid" value
="<?php echo $sid; ?>">
326 <input type
="hidden" name
="lang" value
="<?php echo $lang; ?>">
327 <INPUT type
="submit" value
="<?php echo $LDCancel ?>"></font
></FORM
>
342 require($root_path.'include/inc_load_copyrite.php');