Чтение RSS каналов

Форум

Открыть Ответить

Help

0

0
1
10.02.2010 12:47:19
Sorry , but i dont understand russian so i write in english !

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&#257;kais lietot&#257;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

http://www.bildem.lv/bilde/123_1265802369.jpg

I want my script in the block ! Please some one help me :)


Версия системы: SLAED CMS 4.1 Pro
Версия PHP: PHP 4
Сервер: Сервер в интернете
2
10.02.2010 15:04:46
bad => echo"";

good => $content ="";
3.74

3.74
3
10.02.2010 15:39:5410.02.2010 15:43:20
Still didnt understand nothing from you , so how my code need to look?

EDIT: THX all ok !
4
10.02.2010 16:54:23
$content = '
<font size="2">
Registrejusies: '.$reg.'<br />
Online: '.$kopa.'<br />
Viesi: '.$viesi.'<br />
Lietotaji: '.$regon.'<br />
Jaun&#257;kais lietot&#257;js: <a href=http://independentgaming.hpx.lv/forum/index.php?showuser='.$newest2['id'].'>'.$newest2['members_display_name'].'</a>
<hr style="margin:2px 0;"/>
</font>';
3.74

3.74
Открыть Ответить
Хотите опробовать SLAED CMS в действии?

Технологии

PHP MySQL HTML 5 CSS 3 jQuery jQuery UI

Контакты

  • D-49179, Deutschland
    Ostercappeln, Im Siek 6
  • +49 176 61966679

  • https://slaed.net
Идеи и предложения
Обратная связь