SitePoint Sponsor

User Tag List

Results 1 to 3 of 3

Hybrid View

  1. #1
    SitePoint Addict
    Join Date
    Aug 2005
    Posts
    254
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Redirecting with querystrings from Red Hat Linux 5

    Hi I really need to be able to redirect from one web page to another with querystrings. I have been told by IT you cant do this with Red Hat Linux 5 - is this correct? is there anything i can do?

    I need to be able to redirect from

    http://www.open.ac.uk/disability/sec...h-dyslexia.pdf

    to

    www2.open.ac.uk/study/support/disability/orientation/?s=/students/help/studying-with-dyslexia&e=/study/support/disability/publications/studying-with-dyslexia

    Thanks

  2. #2
    SitePoint Wizard
    Join Date
    Oct 2005
    Posts
    1,832
    Mentioned
    5 Post(s)
    Tagged
    1 Thread(s)
    Redirection is usually done with the web server, not the OS. What web server are you running?

  3. #3
    Certified Ethical Hacker silver trophybronze trophy dklynn's Avatar
    Join Date
    Feb 2002
    Location
    Auckland
    Posts
    14,653
    Mentioned
    19 Post(s)
    Tagged
    3 Thread(s)
    S100,

    cd is correct. That does NOT mean that you can't redirect but you must setup Apache on the server AND enable mod_rewrite (see the tutorial linked in my signature for details on that).

    THEN, as the tutorial continues, you need to be able to use the requested URI to develop the "real" (serveable) URI ... which does not appear possible from your example.

    Finally, there are ways to do what you're asking and it's called a RewriteMap (which is only available to you if you have access to the server or virtual host configuration file). There is also a "poor man's RewriteMap" which uses a "handler file" (rather than a simple 404 script) to perform a lookup in a database with the map of old URI matched to the (new?) "real" URI. I fear that's beyond your ability at this point (from your question) but I've discussed this in many threads and in my tutorial ... and am available here if you have questions on this, too.

    Regards,

    DK
    David K. Lynn - Data Koncepts is a long-time WebHostingBuzz (US/UK)
    Client and (unpaid) WHB Ambassador
    mod_rewrite Tutorial Article (setup, config, test & write
    mod_rewrite regex w/sample code) and Code Generator


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
  •