john_bboy7 Posted April 13, 2008 Share Posted April 13, 2008 Can any one tell me the code for auto navigation in php???? Like when press the button in my page then it automatically Go to a specific page... after going to that page it should navigate to other page and so on... I searched it all night but coudnt got it... PLease help me... Quote Link to comment https://forums.phpfreaks.com/topic/100919-need-a-code/ Share on other sites More sharing options...
wildteen88 Posted April 13, 2008 Share Posted April 13, 2008 Umm, can you give a more informative example. Not understanding your question! Do you want something like the following: home > some category > page Like this forum has, eg: PHP Freaks Forums > PHP and MySQL > PHP Help > Topic: Need a code..... If you do then search for PHP breadcrumbs tutorial Quote Link to comment https://forums.phpfreaks.com/topic/100919-need-a-code/#findComment-516080 Share on other sites More sharing options...
dezkit Posted April 13, 2008 Share Posted April 13, 2008 I think this is what you want? index.php <br><br><center><a href="?page=home">Home |</a><a href="?page=about"> About |</a><a href="?page=contact"> Contact</a> <br><br><br></center> <?php $page = $_GET["page"]; if (!$page) { include "home.php"; } else if($page=="home") { include "home.php"; } else if($page=="about") { include "about.php"; } else if($page=="contact") { include "contact.php"; } else { echo "<b><h1>404 Error</h1></b>"; } ?> home.php HOME PAGE about.php ABOUT PAGE contact.php CONTACT PAGE Quote Link to comment https://forums.phpfreaks.com/topic/100919-need-a-code/#findComment-516084 Share on other sites More sharing options...
john_bboy7 Posted April 13, 2008 Author Share Posted April 13, 2008 Umm, can you give a more informative example. Not understanding your question! Do you want something like the following: home > some category > page Like this forum has, eg: PHP Freaks Forums > PHP and MySQL > PHP Help > Topic: Need a code..... If you do then search for PHP breadcrumbs tutorial No its like this: When i press the button then the page Goes to www.google.com then after completing that page it should go yahoo.com and so on... Or much more like a mailer... ??? ??? Means it will b working in background... I saw it some where thats y i m not sure of the coding but i will try to get it.. i will try my best... Until then please suggest me a good tutorial related to this thing... Quote Link to comment https://forums.phpfreaks.com/topic/100919-need-a-code/#findComment-516088 Share on other sites More sharing options...
john_bboy7 Posted April 13, 2008 Author Share Posted April 13, 2008 I think this is what you want? index.php <br><br><center><a href="?page=home">Home |</a><a href="?page=about"> About |</a><a href="?page=contact"> Contact</a> <br><br><br></center> <?php $page = $_GET["page"]; if (!$page) { include "home.php"; } else if($page=="home") { include "home.php"; } else if($page=="about") { include "about.php"; } else if($page=="contact") { include "contact.php"; } else { echo "<b><h1>404 Error</h1></b>"; } ?> home.php HOME PAGE about.php ABOUT PAGE contact.php CONTACT PAGE No the other pages are not pHp... its a normal site... Quote Link to comment https://forums.phpfreaks.com/topic/100919-need-a-code/#findComment-516089 Share on other sites More sharing options...
dezkit Posted April 13, 2008 Share Posted April 13, 2008 Oh, its called meta redirection with frames. Quote Link to comment https://forums.phpfreaks.com/topic/100919-need-a-code/#findComment-516093 Share on other sites More sharing options...
john_bboy7 Posted April 13, 2008 Author Share Posted April 13, 2008 Oh, its called meta redirection with frames. Can u give me an example of the code... plz... Quote Link to comment https://forums.phpfreaks.com/topic/100919-need-a-code/#findComment-516097 Share on other sites More sharing options...
dezkit Posted April 13, 2008 Share Posted April 13, 2008 Meta redirection: You will be redirected to google.com in a couple of seconds. <META http-equiv="refresh" content="5; URL=http://www.google.com/"> FRAMES: http://www.tizag.com/htmlT/frames.php Quote Link to comment https://forums.phpfreaks.com/topic/100919-need-a-code/#findComment-516100 Share on other sites More sharing options...
john_bboy7 Posted April 13, 2008 Author Share Posted April 13, 2008 Meta redirection: You will be redirected to google.com in a couple of seconds. <META http-equiv="refresh" content="5; URL=http://www.google.com/"> FRAMES: http://www.tizag.com/htmlT/frames.php its an html tutorail... ??? ??? Anyhow thanx maN :D Quote Link to comment https://forums.phpfreaks.com/topic/100919-need-a-code/#findComment-516104 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.