215 |
* - |
* - |
216 |
* return: |
* return: |
217 |
*/ |
*/ |
|
|
|
|
|
|
218 |
function FormatString($p_string) |
function FormatString($p_string) |
219 |
{ |
{ |
220 |
if ( !isset ($p_string) ) { |
if ( !isset ($p_string) ) { |
228 |
$p_string=str_replace("'","\'",$p_string); |
$p_string=str_replace("'","\'",$p_string); |
229 |
return $p_string; |
return $p_string; |
230 |
} |
} |
|
/* function GetUserType |
|
|
* Purpose : get the type of an user (compta,developper or user) |
|
|
* |
|
|
* parm : |
|
|
* - param $p_user user_login |
|
|
* gen : |
|
|
* - none |
|
|
* return: the type of the user |
|
|
*/ |
|
|
function GetUserType($p_user) |
|
|
{ |
|
|
$cn=DbConnect(); |
|
|
$Res=ExecSql($cn,"select use_usertype from ac_users |
|
|
where use_login='".$p_user."'"); |
|
|
if ( pg_NumRows($Res) == 0 ) return null; |
|
|
$Ret=pg_fetch_row($Res,0); |
|
|
return $Ret[0]; |
|
|
} |
|
231 |
|
|
232 |
/* function ShowItem($p_array) */ |
/* function ShowItem($p_array) */ |
233 |
/* purpose : store the string which print */ |
/* purpose : store the string which print */ |