Sorry , but i dont understand russian so i write in english !
Question -
How i can get a php code into a block?
for example
When i write it in block file i have this
I want my script in the block ! Please some one help me :)
Question -
How i can get a php code into a block?
for example
<?php
$db_host='localhost';
$db_user='****';
$db_pass='****';
$db_name='****';
mysql_connect($db_host,$db_user,$db_pass)or die(mysql_error());
mysql_select_db($db_name)or die(mysql_error());
$reg = mysql_query("SELECT * FROM ibf_members");
$reg = mysql_num_rows($reg);
$newest = mysql_query("SELECT * FROM ibf_members ORDER BY id DESC LIMIT 1 ");
$newest2 = mysql_fetch_array($newest);
$delay = "900";
$delays = time() - $delay;
$useri = mysql_query("SELECT * FROM ibf_members WHERE last_activity >= ".$delays."");
$regon = mysql_num_rows($useri);
$viesi = mysql_query("SELECT * FROM ibf_sessions WHERE member_id = '0' and running_time >= ".$delays."");
$viesi = mysql_num_rows($viesi);
$kopa = $regon + $viesi;
echo '
<font size="2">
Registrejusies: '.$reg.'<br />
Online: '.$kopa.'<br />
Viesi: '.$viesi.'<br />
Lietotaji: '.$regon.'<br />
Jaunākais lietotājs: <a href=http://independentgaming.hpx.lv/forum/index.php?showuser='.$newest2['id'].'>'.$newest2['members_display_name'].'</a>
<hr style="margin:2px 0;"/>
</font>';
?>
$db_host='localhost';
$db_user='****';
$db_pass='****';
$db_name='****';
mysql_connect($db_host,$db_user,$db_pass)or die(mysql_error());
mysql_select_db($db_name)or die(mysql_error());
$reg = mysql_query("SELECT * FROM ibf_members");
$reg = mysql_num_rows($reg);
$newest = mysql_query("SELECT * FROM ibf_members ORDER BY id DESC LIMIT 1 ");
$newest2 = mysql_fetch_array($newest);
$delay = "900";
$delays = time() - $delay;
$useri = mysql_query("SELECT * FROM ibf_members WHERE last_activity >= ".$delays."");
$regon = mysql_num_rows($useri);
$viesi = mysql_query("SELECT * FROM ibf_sessions WHERE member_id = '0' and running_time >= ".$delays."");
$viesi = mysql_num_rows($viesi);
$kopa = $regon + $viesi;
echo '
<font size="2">
Registrejusies: '.$reg.'<br />
Online: '.$kopa.'<br />
Viesi: '.$viesi.'<br />
Lietotaji: '.$regon.'<br />
Jaunākais lietotājs: <a href=http://independentgaming.hpx.lv/forum/index.php?showuser='.$newest2['id'].'>'.$newest2['members_display_name'].'</a>
<hr style="margin:2px 0;"/>
</font>';
?>
When i write it in block file i have this
I want my script in the block ! Please some one help me :)
Версия системы: SLAED CMS 4.1 Pro
Версия PHP: PHP 4
Сервер: Сервер в интернете