<?php
function configure($file)
{
$file=parse_ini_file($file,true);
foreach($file as $key => $value)
foreach($value as $k => $val)
{
global ${strtoupper($key.'_'.$k)};
${strtoupper($key.'_'.$k)}=$val;
}
}
#функция вывода формы авторизации
function aut_form($hidden='', $to=NULL)
{
if($to==NULL) $to=$_SERVER['PHP_SELF'];
echo '<form method="get" action="'.$to.'">'."\n";
echo '<div><fieldset>'."\n";
echo '<legend>Войти</legend>';
echo 'Логин:<br />'."\n";
echo '<input type="text" name="login" maxlength="32" /><br />'."\n";
echo 'Пароль:<br />'."\n";
echo '<input type="password" name="passw" maxlength="32" /><br />'."\n";
echo $hidden;
echo '<input type="submit" value="Войти" />'."\n".'</fieldset></div>'."\n".'</form>'."\n";
}
#реклама вверху
function rekl_top($way, $path='/system/conf/top.cati')
{
include $way.'/'.$path;
return true;
}
#реклама внизу
function rekl_bottom($way, $path='system/conf/bottom.cati')
{
include $way.'/'.$path;
return true;
}
?>