html - PHP !_GET displays blank page -
so url:
http://myawesomesite.com/base.php?file=myawesomefile
and base.php file:
<?php if (is_file("$_get["file"].inc.php")) include ("$_get["file"].inc.php"); else include("homepage.inc.php"); ?> this results in blank page. doing wrong?
thanks in advance. cheers!
you're using double quotes in is_file() function , in $_get variable. they're in eachothers way.
use this:
if (is_file("$_get['file'].inc.php")) include ("$_get['file'].inc.php"); al though i'm not sure have right should give error , not blank page.
Comments
Post a Comment