uri/url help

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I'm trying to make something to redirect people to my home page if they some how access my include pages.  For example, I have a generic copyright .htm with links in it that I add to all my pages with the include().  Problem is when I'm trying to make it the uri is always where it is in the include folder I made, even when I'm on the home page trying to view the links.  This is what I have:

<?
  $uri=$_SERVER["REQUEST_URI"];
  if($uri=='/'.strpbrk($uri, 'include')){header("Location: ../index.php");}
  else{
?>
<p>page content</p>
<? } ?>

But the error is that since it always returns the /include/...htm uri even when I'm viewing it on http://www.domain.com/index.php

Help please! Thank you!

_____________________________________________

Kenton P. Kammer

E1: kpkammer@xxxxxxxxx
E2: kkammer@xxxxxxxxxxxxxxxx
P:  (309)677-1152
C:  (708)309-1876
F:  (708)263-4424
_____________________________________________
       

[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux