SitePoint Sponsor

User Tag List

Results 1 to 6 of 6
  1. #1
    illegal ********* immigrant
    Join Date
    Jul 2005
    Posts
    199
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    GET/POST still functionnal after mod_rewrite?

    let's say my url is the following:

    (http://domain/category/type/)
    http://myblog.com/fish/goldfish/

    before mod rewrite this was possible:

    PHP Code:
    $category $_GET['category'];
    $type $_GET['type']; 
    Would I still be able to retreive $_GET after the mod_rewrite ?

    Thank you!

  2. #2
    SitePoint Member
    Join Date
    Jun 2006
    Posts
    1
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Yes its still working.

  3. #3
    SitePoint Wizard silver trophy
    Join Date
    Mar 2006
    Posts
    6,132
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    it can be made to still work.
    but it may not work depending on how you created your rewrite rule.

  4. #4
    SitePoint Zealot krt's Avatar
    Join Date
    Sep 2005
    Location
    Australia
    Posts
    114
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    (Using an example mod_rewrite scenario)

    Just remember that usually, the user sees this:
    /profile/bob.htm

    The server side script sees this:
    /?cmd=profile&user=bob

  5. #5
    SitePoint Addict
    Join Date
    Jan 2002
    Location
    Southwest Florida
    Posts
    393
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    And you can always test this for yourself by doing

    PHP Code:
    print_r($_GET); 

  6. #6
    illegal ********* immigrant
    Join Date
    Jul 2005
    Posts
    199
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks guys


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
  •