FRIHOST FORUMS SEARCH FAQ TOS BLOGS COMPETITIONS
You are invited to Log in or Register a free Frihost Account!


php script in php nuke - need help!





Slick
hi i have installed php - nuke

and have created a new block called - Broadcast Status and created a block file named - block-Broadcast_Status.php

im tryin to get this php sript to appear in the Broadcast Status box

http://slick96fm.frihost.net/radio/ganjabeatsonoffmain.php

the code i have in the block script is

Code:
<?php

if (eregi("block-Broadcast_Status.php",$PHP_SELF)) {
    Header("Location: index.php");
    die();
}

$content  .= "test<br>";
$content  .= "testing<br>";
$content  .= "<center><?php include
\"http://slick96fm.frihost.net/radio/ganjabeatsonoffmain.php\"; ?></center> ";

?>


the test and testing text appear but not the script!

if i use sominthing like this

Code:

<?php

if (eregi("block-Broadcast_Status.php",$PHP_SELF)) {
    Header("Location: index.php");
    die();
}

@include("http://slick96fm.frihost.net/radio/ganjabeatsonoffmain.php");
$content  .= "test<br>";
$content  .= "testing<br>";

?>


then the script appears but is above (outside/sitting on top) of the Broadcast Status box

Please help!

thank you
Slick
Finally figured it!

simple really

Code:

<?php

if (eregi("block-Broadcast_Status.php",$PHP_SELF)) {
    Header("Location: index.php");
    die();
}

ob_start();
include("http://slick96fm.frihost.net/radio/ganjabeatsonoffmain.php");
$output = ob_get_contents();
ob_end_clean();
$content = $output;


?>
Related topics
Reply to topic    Frihost Forum Index -> Scripting -> Php and MySQL

FRIHOST HOME | FAQ | TOS | ABOUT US | CONTACT US | SITE MAP
© 2005-2011 Frihost, forums powered by phpBB.