Location: PHPKode > projects > QuickTicket > quickticket/qti_adm_const.php
<?php 

// QuickTicket 2.5 build:20101222

session_start();
require_once('bin/qti_init.php');
if ( $oVIP->role!='A' ) die('Access denied');
$oVIP->selfurl='qti_adm_const.php';

function ConstantToString($str)
{
  if ( is_string($str) ) return '"'.str_replace('&','&amp;',$str).'"';
  if ( is_bool($str) ) return ($str ? 'TRUE' : 'FALSE');
  if ( is_array($str) ) return 'array of '.count($str).' values';
  return $str;
}

// HTML start

include(Translate('qti_adm.php'));
include('qti_adm_p_header.php');

// CONSTANT

echo '<p>Here are major constants. To have a full list of constants see the file /bin/qti_ini.php.</p>';

echo '
<table class="data_o" cellspacing="0">
<colgroup span="2"><col width="200"></col><col></col></colgroup>
<tr class="data_o">
<td class="colhd colhdfirst">QT</td>
<td class="colct">'.ConstantToString(constant('QT')).'</td>
</tr>
';

foreach(array('BACKBUTTON','DFLT_VIEWMODE','SHOW_VIEWMODE','SHOW_CONTRAST','SHOW_PRINT','SHOW_TIME','SHOW_MEMBERLIST','SHOW_MODERATOR','SHOW_GOTOLIST','SHOW_DOMAIN','USE_COPPA','CHILDREN','CRUMBTRAIL','MENUSEPARATOR','NOTIFY_NEWACTOR','NOTIFY_OLDACTOR','CONVERT_AMP','SIMPLESEARCH ','DIR_PIC','DIR_DOC','LIST_ME','LIST_TAG','JAVA_MAIL','WEEKSTART','STAFFEDITSTAFF','STAFFEDITADMIN','URLREWRITE') as $str)
{
if ( defined('QTI_'.$str) ) echo '<tr class="data_o"><td class="colhd colhdfirst">QTI_'.$str.'</td><td class="colct" >'.ConstantToString(constant('QTI_'.$str)).'&nbsp;</td></tr>',N;
}

echo '
</table>
';

// DB PARAMETERS

echo '<p>Here are the database connection parameters</p>';

echo '
<table class="data_o" cellspacing="0">
<colgroup span="2"><col width="200"></col><col></col></colgroup>
';
foreach(array('qti_dbsystem','qti_host','qti_database','qti_prefix','qti_user','qti_port','qti_dsn','qti_install') as $str)
{
if ( isset($$str) ) echo '<tr class="data_o"><td class="colhd colhdfirst">$'.$str.'</td><td class="colct" >'.$$str.'&nbsp;</td></tr>',N;
}
echo '
</table>
';

include('qti_adm_p_footer.php');

?>
Return current item: QuickTicket