b3pot6 Posted March 9, 2009 Share Posted March 9, 2009 Hi, I'm developing a website and I have some php code that makes the main content area of the page change while leaving all other parts of the website as is. The problem is that this code makes Safari and IE crash, it makes Opera display the page all screwed up and then makes it crash and it makes Chrome really slow. Here's the code.. <?php //If is defined URL variable 'signup' if(isset($_GET['signup'])){ // include page signup include('include/in-signup.php'); //else if is defined URL variable 'login' }else if(isset($_GET['login'])){ // include page login include('include/in-login.php');} //else if is defined URL variable 'about' else if(isset($_GET['about'])){ // include page 'about' include('include/in-about.php');} // in all other cases include the home page } else { include('include/in-home.php'); } ?> I have included this code into the main content area of the page. Can anyone please help? Link to comment https://forums.phpfreaks.com/topic/148634-my-php-code-is-making-my-browsers-crash/ Share on other sites More sharing options...
ILYAS415 Posted March 9, 2009 Share Posted March 9, 2009 try... <? if ($_GET['signup']){ $page="signup.php"; }elseif ($_GET['login']){ $page="login.php"; } //you can carry it on from here //then u do include... include "include/".$page.""; ?> [code] Link to comment https://forums.phpfreaks.com/topic/148634-my-php-code-is-making-my-browsers-crash/#findComment-780505 Share on other sites More sharing options...
b3pot6 Posted March 9, 2009 Author Share Posted March 9, 2009 It's working now. Thank you VERY VERY much. Link to comment https://forums.phpfreaks.com/topic/148634-my-php-code-is-making-my-browsers-crash/#findComment-780512 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.