Results 1 to 11 of 11

Thread: Redirect

  1. #1
    5 Star Lounger
    Join Date
    May 2001
    Location
    Allen, Texas, USA
    Posts
    727
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Redirect

    Is there a way to redirect people that type in www.xxx/forms to go directly to www.xxx.forms.HTML?

    Thanks!
    --KZ

  2. #2
    Super Moderator WebGenii's Avatar
    Join Date
    Jan 2001
    Location
    Redcliff, Alberta, Canada
    Posts
    4,066
    Thanks
    2
    Thanked 5 Times in 5 Posts

    Re: Redirect

    how about the meta refresh tab
    meta http-equiv="refresh" content="0;URL=http://www.www.xxx.forms.HTML"
    [b]Catharine Richardson (WebGenii)
    WebGenii Home Page
    Moderator: Spreadsheets, Other MS Apps, Presentation Apps, Visual Basic for Apps, Windows Mobile

  3. #3
    5 Star Lounger
    Join Date
    May 2001
    Location
    Allen, Texas, USA
    Posts
    727
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Re: Redirect

    Thanks for your reply.
    Help me out here...so...what are you suggesting to do?

    I'm trying to get where people accidentally put in www.xxx.forms and I want that to direct to www.xxx.forms/html

    --KZ

  4. #4
    Super Moderator WebGenii's Avatar
    Join Date
    Jan 2001
    Location
    Redcliff, Alberta, Canada
    Posts
    4,066
    Thanks
    2
    Thanked 5 Times in 5 Posts

    Re: Redirect

    Place the code in the meta tag section of the www.xxx.forms default page (this is decided by your server, usually defaults to something like default.html or index.html or index.asp - if you don't know ask your web server administrator).
    [b]Catharine Richardson (WebGenii)
    WebGenii Home Page
    Moderator: Spreadsheets, Other MS Apps, Presentation Apps, Visual Basic for Apps, Windows Mobile

  5. #5
    5 Star Lounger
    Join Date
    May 2001
    Location
    Allen, Texas, USA
    Posts
    727
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Re: Redirect

    OK, I don't want the main index page to redirect, but the lower level page. www.webpage/forms to go to www.webpage/forms/forms.html.
    Is that possible?

    --KZ

  6. #6
    Super Moderator WebGenii's Avatar
    Join Date
    Jan 2001
    Location
    Redcliff, Alberta, Canada
    Posts
    4,066
    Thanks
    2
    Thanked 5 Times in 5 Posts

    Re: Redirect

    If you have a default document with the meta tag in the webpage/forms directory, yes.
    [b]Catharine Richardson (WebGenii)
    WebGenii Home Page
    Moderator: Spreadsheets, Other MS Apps, Presentation Apps, Visual Basic for Apps, Windows Mobile

  7. #7
    5 Star Lounger
    Join Date
    May 2001
    Location
    Allen, Texas, USA
    Posts
    727
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Re: Redirect

    Well...unless I'm doing something wrong, it comes up still with the directory page listing, but doesn't direct anywhere. BUT when I try to click on the actual forms.html from the web directory, it says that it can't be displayed.

    Help

  8. #8
    Super Moderator jscher2000's Avatar
    Join Date
    Feb 2001
    Location
    Silicon Valley, USA
    Posts
    23,112
    Thanks
    5
    Thanked 93 Times in 89 Posts

    Re: Redirect

    To some extent it depends on your host. Many hosts allow you to set up a special global 404 (page not found) handler which you can point to a script that figures out exactly what to do for missing pages (in the case of this folder, if there's no default.html or index.html it would generate a 404 error). That's probably the easiest way. If you control the server, you probably have more options.

  9. #9
    5 Star Lounger
    Join Date
    May 2001
    Location
    Allen, Texas, USA
    Posts
    727
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Re: Redirect

    Actually there is a default / index.html page, but it's not at that location.

    Is there no way to do what I'm trying to do then?

    --KZ

  10. #10
    Super Moderator jscher2000's Avatar
    Join Date
    Feb 2001
    Location
    Silicon Valley, USA
    Posts
    23,112
    Thanks
    5
    Thanked 93 Times in 89 Posts

    Re: Redirect

    Each folder can have (or needs to have) its own default. It's considered unsafe to let visitors see the directory listing. So use Catharine's redirect code in a default page in the forms folder and you should be good to go without any server-side trickery. By the way, it's common to include a link saying something to the effect of "if you are not automatically redirected, click here," just in case there is an issue with the browser's implementation of the META REFRESH tag.

  11. #11
    5 Star Lounger
    Join Date
    May 2001
    Location
    Allen, Texas, USA
    Posts
    727
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Re: Redirect

    Actually, what I ended up doing was using the redirct tab, but I had to put it in an index.html file. Maybe I missed that part. But I got it to work now.

    <meta http-equiv="refresh" content="0;url=http://www.webpage.com/test.html">

    Interesting comment about having a rediect page for each directly. I like that! Good security.

    --KZ

Posting Permissions

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