SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Evangelist
    Join Date
    Apr 2007
    Posts
    398
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    $_server['php_self'];

    Hi Guys,

    Bit confused. Obviously <?php echo $_SERVER['PHP_SELF']; ?> gets you the URL of the current page, but say my page is:

    http://www.mywebsitedomainnamehere.c...ndex.php?id=12

    It just returns

    www.mywebsitedomainnamehere.co.uk/index.php

    How do I get the additional info?

    Thanks

    Chris

  2. #2
    SitePoint Guru
    Join Date
    Dec 2005
    Posts
    982
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    $_SERVER['REQUEST_URI']
    or
    $_SERVER['PHP_SELF'].'?'.$_SERVER['QUERY_STRING']
    MySQL v5.1.58
    PHP v5.3.6

  3. #3
    .* draziW tnioPetiS *. bronze trophy
    Join Date
    Jun 2004
    Location
    "Then I figure the most good good guy will win."
    Posts
    1,666
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    See also: Predefined Variables

    Good luck!
    Cheers,
    M


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •