dmccabe Posted May 29, 2008 Share Posted May 29, 2008 I have been working on a corporate intranet for the company I work for and up until today it only had one page, so today I went about adding some new pages I was working on and made a change to the index.php (main page) and now it comes up blank? Old Code: <?php $title = $title."Home"; include('header.php'); if (isset($_GET['page']) && $_GET['page'] == 'corpaccount') { include('callcentre/corpaccount.php'); } else { ?> <br />Welcome to the 1car1 index page<a href="#">blah</a> <?php } //include('footer.php'); ?> New Code: <?php $title = $title."Home"; include('header.php'); if (isset($_GET['page'])) { if ($_GET['page'] == 'callcentre_corpaccount') { include('callcentre/corpaccount.php'); } elseif ($_GET['page'] == 'it_new_user') { include('it/new_user.php') } } else { ?> <br />Welcome to the index page<a href="#">blah</a> <?php } //include('footer.php'); ?> why the blank page? Quote Link to comment https://forums.phpfreaks.com/topic/107803-solved-slight-change-in-code-now-i-have-blank-page-why/ Share on other sites More sharing options...
rhodesa Posted May 29, 2008 Share Posted May 29, 2008 If you turn on error reporting or look in your PHP error logs, you will see that you are missing a semi-colon at the end of this line: include('it/new_user.php') Quote Link to comment https://forums.phpfreaks.com/topic/107803-solved-slight-change-in-code-now-i-have-blank-page-why/#findComment-552622 Share on other sites More sharing options...
dmccabe Posted May 29, 2008 Author Share Posted May 29, 2008 Something about wood's and tree's I think goes here Thanks again Rhodesa! I wasnt aware I had error reporting turned off, how do I turn it back on? (am using WAMP server it that helps?) Quote Link to comment https://forums.phpfreaks.com/topic/107803-solved-slight-change-in-code-now-i-have-blank-page-why/#findComment-552632 Share on other sites More sharing options...
.josh Posted May 29, 2008 Share Posted May 29, 2008 If I remember correct, you can toggle it in wamp's settings menu, or you can edit the config file yourself, or you can toggle it in your actual script with this: http://us.php.net/error_reporting Quote Link to comment https://forums.phpfreaks.com/topic/107803-solved-slight-change-in-code-now-i-have-blank-page-why/#findComment-552728 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.