GET command impeding factors

Discussion in 'PHP' started by Luke Jones, Jul 23, 2007.

  1. #1
    Hello,
    What circumstances would cause a $_GET command of the url to not work?
    I have correct code, which is working on other pages, but will not work on one particular page. The only difference is that the url is a rewrite, not the original.
    Please give me your suggestions.

    Thanks,

    Luke
     
    Luke Jones, Jul 23, 2007 IP
  2. exodus

    exodus Well-Known Member

    Messages:
    1,900
    Likes Received:
    35
    Best Answers:
    0
    Trophy Points:
    165
    #2
    What do you mean not original and it is a rewrite. Example of what you are talking about. Because I know of htaccess rewrite, but that could be something different then what your talking about.
     
    exodus, Jul 23, 2007 IP
  3. Luke Jones

    Luke Jones Peon

    Messages:
    427
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    Hello,
    Yes, I'm talking about htacess rewrite.
    I've just resolved the problem using $url = ($_SERVER['REQUEST_URI']);
    but still the question remains: why didn't my GET command work on this page?
     
    Luke Jones, Jul 23, 2007 IP
  4. exodus

    exodus Well-Known Member

    Messages:
    1,900
    Likes Received:
    35
    Best Answers:
    0
    Trophy Points:
    165
    #4
    What does the htaccess line look like. I don't think your doing it correctly.
     
    exodus, Jul 23, 2007 IP
  5. ds316

    ds316 Peon

    Messages:
    154
    Likes Received:
    11
    Best Answers:
    0
    Trophy Points:
    0
    #5
    yep what the rewrite is doin is 'redirecting' the page, but it is not passing the url's query string data to the php page, thereofre your $_GET variables aren't being parsed.
     
    ds316, Jul 23, 2007 IP
  6. Luke Jones

    Luke Jones Peon

    Messages:
    427
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #6
    Yes, that's exactly what's happening. I don't know why, because my rewrite is correct.
    Anyway, I've resolved this using an url basename extract.

    Thanks.
     
    Luke Jones, Jul 23, 2007 IP