AlternativeNick 0 Report post Posted June 21, 2006 firstly, id like to show you what im looking for.id like a site where it is something like this http://forums.xisto.com/no_longer_exists/ and where 10 is, it specifies a specific page, and then something.php adds that page as its content using an include. I know it has something to do with GET, but i have no idea how to do this, so any help would be awesome Share this post Link to post Share on other sites
rvalkass 5 Report post Posted June 21, 2006 So, just to clarify: You want to be able to specify a page in the URL which will then be loaded into something.php? Such as something.php?page=cheese would load cheese.php? If that's what you want then this code should work: <?php$page = $_GET['page'];$page = $page . ".php";include($page);?>I haven't tried that code but it should work if you just put that where you want the page in the URL to appear. It also relies on the page you want to load being in the same directory as something.phpAlso, rather than just ?=10 you have to use ?page=10 to get it to work. Feel free to PM me, email me or get me on MSN if you want any more help. Share this post Link to post Share on other sites
AlternativeNick 0 Report post Posted June 21, 2006 i figured it out just before i saw this.. i figured hey, in a GET form, it puts the info into the address bar like that, so i can use $_GET and for sure, it worked. If youd like to see how it ended up working, you can check it out herehttp://forums.xisto.com/no_longer_exists/Thanks! Share this post Link to post Share on other sites
asyn 0 Report post Posted June 26, 2006 Just be careful of include()ing a parameter passed from the URL. That is an easy to exploit weakness by hackers and can cause stuff to be included that you don't want to be.For example:http://www.example.com/?page=../../../../etc/passwdNow I know with Xisto they are tight on security and that wouldn't work, but you get the point. just by substituting your URL data with their own they can expose sensitive data on your site. Share this post Link to post Share on other sites