View Full Version : Help with html url
05-15-2009, 10:31 AM
Hi, what I want to do is to be able to take information from a requested url and use it to display a web page. For example, lets say I enter in the url www.mysite.com/hello.html. even though the file hello.html does not exist on my server, I want a web page to be displayed that uses the word given in the requested url in it. This way I would be able to have a page customized to say anything that is requested. I know this can be done somehow because i see it used all the time. Hope you understand what I am asking. Thanks!
05-15-2009, 01:26 PM
05-21-2009, 10:47 PM
Thanks, but when i use this it gives me the slash before the file name i.e. "/hello". is there anyway to not have the slash returned?
05-21-2009, 11:11 PM
Give this a shot...
echo substr($_SERVER['REQUEST_URI'],1] )
05-21-2009, 11:45 PM
A much better way to do that is using a simple php page. The urls should be like:
and then the selection of the file to show is done like:
case 'register': break;
$page = 'home';
Powered by vBulletin® Version 4.2.2 Copyright © 2017 vBulletin Solutions, Inc. All rights reserved.