Application Name as variable

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]

  • [B]curent_directory !== app_name[/B]
  • [B]curent_directory === friendly_URL[/B]
  • and if not set Friendly URL then [B]curent_directory === app_name[/B] [/LIST] [B]And of course there is a build in variables contains some project and app info:[/B]
    
    // 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