Is there any build in variable in SC that holds currently open Application Name - so I can read it/display it ?
Arthur
Is there any build in variable in SC that holds currently open Application Name - so I can read it/display it ?
Arthur
See my other post. I don’t know if it’s available but look into the xxxxx_ini procedure to look for the available globals. It’s at least possible with php to retrieve the url, which contains the same info of course.
The current application name can be derived from FILE php magical constant. And DIR is sometimes usefull as well…
[SIZE=26px]Be aware of that:[/SIZE] [LIST=1]
// onScriptInit event
$self = $_SERVER['PHP_SELF'];
echo "Project name : " . $this->Ini->nm_grupo .'<br>';
echo "Project ver. : " . $this->Ini->nm_grupo_versao .'<br>';
echo "Current app : " . $this->Ini->nm_cod_apl .'<br>';
echo '<br>frendly_name V1: '. basename(dirname($self));
echo "<br>frendly_name V2: ".basename(pathinfo($self, PATHINFO_DIRNAME));
echo '<br>called_script : '. basename($self);
echo '<br>curent_file : '. basename(__FILE__);
… continue
3. And if not set Frendly URL then curent_directory === app_name