1. Computer problem? Tech Support Guy is completely free -- paid for by advertisers and donations. Click here to join today! If you're new to Tech Support Guy, we highly recommend that you visit our Guide for New Members.

URLs without the file extension

Discussion in 'Web Design & Development' started by nightqueen, Nov 7, 2007.

Thread Status:
Not open for further replies.
Advertisement
  1. nightqueen

    nightqueen Thread Starter

    Joined:
    Jul 26, 2004
    Messages:
    57
  2. Elvandil

    Elvandil

    Joined:
    Aug 1, 2003
    Messages:
    51,988
    Could you do a redirect from index.htm when the typed address was not found? That would redirect to the same page for all mistyped url's, of course.
     
  3. Fyzbo

    Fyzbo

    Joined:
    Feb 6, 2002
    Messages:
    1,683
    I am assuming from the asp extension that you are using classic asp.

    You may be able to find an isapi filter for iis to redirect the links, but it will most likely be difficult. www.stoneycove.com/nemos actually points to the folder nemos in the root of the website. If you were to create that folder iis would show the default page in that folder, often default.asp, default.html, etc.
     
  4. MMJ

    MMJ Guest

    Joined:
    Oct 15, 2006
    Messages:
    3,625
    Make a file called nemos, than make an ajax request to nemos.asp. not very clean but it works. ;)
     
  5. tomdkat

    tomdkat Retired Trusted Advisor

    Joined:
    May 6, 2006
    Messages:
    7,148
    Why an AJAX request vs a META page redirect or something like that?

    Peace...
     
  6. MMJ

    MMJ Guest

    Joined:
    Oct 15, 2006
    Messages:
    3,625
    Yeah, that makes more sense but if he wants to make it so that the url doesn't show the file extension as said in the thread title.
     
  7. namenotfound

    namenotfound

    Joined:
    Apr 30, 2005
    Messages:
    3,012
    META redirects can "break" the back button.
     
  8. MMJ

    MMJ Guest

    Joined:
    Oct 15, 2006
    Messages:
    3,625
    They do break the back button but in this case I think it would be preferable if it did break.
     
  9. tomdkat

    tomdkat Retired Trusted Advisor

    Joined:
    May 6, 2006
    Messages:
    7,148
    Hmmm, I didn't get that from the description of the issue and the thread title could refer to URLs entered without a file extension in addition to intentionally not wanting to display the file extension in the URL for the loaded page, as you have indicated.

    I read the issue as the user specifies a URL of http://www.blah.com/page and a "not found" is probably returned instead of page.[whatever extension is desired] being returned.

    Peace...
     
  10. nightqueen

    nightqueen Thread Starter

    Joined:
    Jul 26, 2004
    Messages:
    57
    Thanks for all your input. I should probably have explained it all a bit better in the first place. Displaying the default page in a folder is probably the most simple way for me to achieve what I want as it's only the 'homepage of the subpages' I want the shortened URL for.

    Thanks :).
     
  11. Sponsor

As Seen On
As Seen On...

Welcome to Tech Support Guy!

Are you looking for the solution to your computer problem? Join our site today to ask your question. This site is completely free -- paid for by advertisers and donations.

If you're not already familiar with forums, watch our Welcome Guide to get started.

Join over 733,556 other people just like you!

Thread Status:
Not open for further replies.

Short URL to this thread: https://techguy.org/648963

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice