Hi,
following the HelpDesk sample I have tried to create my little project. For this project I use a library that contain the function LoadSettings.
In the first app (it is a startup control) I call LoadSettings in the event onScriptInit and this is the output:
The button Administrator Call the control login. The onScriptInit in the login control call the function LoadSettings. But the opened page is blank and using Firebug I see this error:
If I create in the login control a method with the same code and in onScriptInit call this method, all work fine and this is the output:
The code of function is :
//__NM____NM__FUNCTION__NM__//
function LoadTableSettings(){
$str_sql = "SELECT
SYS_SMTPSERVER,
SYS_SMTPPORT,
SYS_SMTPUSER,
SYS_SMTPPASSWORD,
SYS_SMTPSECURITYFLAG,
SYS_COMPANYNAME,
SYS_EMAILACCOUNT,
SYS_ASSIGMENTMODE,
SYS_DEFINEDPARAMETERS,
SYS_DEFAULTPRIORITY,
SYS_DEFAULTLANGUAGE,
SYS_VERSION
FROM
SYSECLIPSE.SYS_SETTINGS
WHERE
SYS_ID = 1";
sc_lookup(dataset, $str_sql);
$arr_load = array();
$arr_load['SYS_SMTPSERVER'] = (!empty({dataset}[0][0]))?{dataset}[0][0]:'';
$arr_load['SYS_SMTPPORT'] = (!empty({dataset}[0][1]))?{dataset}[0][1]:'';
$arr_load['SYS_SMTPUSER'] = (!empty({dataset}[0][2]))?{dataset}[0][2]:'';
$arr_load['SYS_SMTPPASSWORD'] = (!empty({dataset}[0][3]))?{dataset}[0][3]:'';
$arr_load['SYS_SMTPSECURITYFLAG'] = (!empty({dataset}[0][4]))?{dataset}[0][4]:'';
$arr_load['SYS_COMPANYNAME'] = (!empty({dataset}[0][5]))?{dataset}[0][5]:'';
$arr_load['SYS_EMAILACCOUNT'] = (!empty({dataset}[0][6]))?{dataset}[0][6]:'';
$arr_load['SYS_ASSIGMENTMODE'] = (!empty({dataset}[0][7]))?{dataset}[0][7]:'';
$arr_load['SYS_DEFINEDPARAMETERS'] = (!empty({dataset}[0][8]))?{dataset}[0][8]:'';
$arr_load['SYS_DEFAULTPRIORITY'] = (!empty({dataset}[0][9]))?{dataset}[0][9]:'';
$arr_load['SYS_DEFAULTLANGUAGE'] = (!empty({dataset}[0][10]))?{dataset}[0][10]:'it;it_it';
$arr_load['SYS_VERSION'] = (!empty({dataset}[0][11]))?{dataset}[0][11]:'';
$_SESSION['EclipseSettings'] = $arr_load;
}
?>
I work with Oracle DB.
Have You an Idea ?
Thank You and Best Regards
Gaetano