PDA

View Full Version : A simple PHP Question


Logikos
04-25-2003, 12:33 AM
Okay well im kinda new to php :-P and i made a advertise.php file. All i want it to do is show the "header" require('./global.php'); and the footer and then my one template in the middle of that. i;ve tried a few things but cant get it down >_< heres what i was trying. Maybe youy can tell me what im going wrong.
<?php

require('./global.php');
if (!$bbuserinfo[userid]) {
show_nopermission();
}
eval("dooutput(\"".gettemplate {{'advertise'}}."\");");

?>

I would also like guest to be able to see it also. how can i go back and forth on doing this

Thanks
-Nem

Logician
04-25-2003, 11:17 AM
<?php
$templatesused.='mytemplate';
require('./global.php');
eval("dooutput(\"".gettemplate("mytemplate")."\");");
exit;
?>

* Save this as "advertise.php" and put it in your forum directory.
* Create your template named as "mytemplate". If you have more than 1 styles, create the templates in all.
* Use $header and $footer variables within the template

Logikos
04-25-2003, 04:24 PM
Sweet works great