Location: PHPKode > projects > QuickTalk Forum > quicktalk/qtf_adm_const.php
<?php 

// QuickTalk 2.5 build:20100924

session_start();
require_once('bin/qtf_init.php');
if ( $oVIP->role!='A' ) die('Access denied');
$oVIP->selfurl='qtf_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('qtf_adm.php'));
include('qtf_adm_p_header.php');

// CONSTANT

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

echo '
<table class="data_o" cellspacing="0" summary="constants">
<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('QTF_'.$str) ) echo '<tr class="data_o"><td class="colhd colhdfirst">QTF_'.$str.'</td><td class="colct" >'.ConstantToString(constant('QTF_'.$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('qtf_dbsystem','qtf_host','qtf_database','qtf_prefix','qtf_user','qtf_port','qtf_dsn','qtf_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('qtf_adm_p_footer.php');

?>
Return current item: QuickTalk Forum