Do you have a question? Post it now! No Registration Necessary. Now with pictures!
- Posted on
- PHP Selective redirection
December 19, 2009, 9:58 pm
rate this thread
I`ve index.php that sits in the root. I want to include index1.php if
there are no query strings OR subdirectory passed in the URL
i.e. if http://www.example.com -> redirect to index1.php
if http://www.example.com/something-else OR http://www.example.com/?p=332
-> redirect to index2.php
How do i identify subdirectory or query string in the "Requested url"
so that i can achieve this redirection
Re: PHP Selective redirection
You should be looking at your web server configuration, not PHP. Try
alt.apache.configuration (assuming, of course, you're using Apache - if
you're using IIS, you're SOL).
Here's a hint - PHP doesn't get involved until the page gets loaded in
the server. What you're asking is how to load a page OTHER than that
requested - which is generally web server configuration.
Remove the "x" from my email address
JDS Computer Training Corp.