Discussion: website tree
Afficher un message
Vieux 05/01/2008, 18h18   #2
John Gunther
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: website tree

Get the various parts from the $_SERVER superglobal variable:
1) scheme (e.g. http://) from $_SERVER['HTTPS'] (https if "on")
2) host:port (e.g. bucksvsbytes.com) from $_SERVER['HTTP_HOST']
3) /path/page?query part (e.g. /catalog/index.php?pid=444) from
$_SERVER['REQUEST_URI']

John Gunther
Alain Roger wrote:
> Hi,
>
> let's imaging we have the following thing :
>
> www.mywebsite.com/company/index.php
> www.mywebsite.com/company/profile.php
> www.mywebsite.com/services/index.php
>
> how can i detect in which address am i ?
>
> for example how to retrieve www.mywebsite.com/services or
> www.mywebsite.com/company
>

  Réponse avec citation
 
Page generated in 0,06723 seconds with 9 queries