Results 1 to 4 of 4

Thread: Extensions

  1. #1
    Join Date
    Dec 2004
    Posts
    83
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question Extensions

    How do I get rid of page extensions?

    Like when I click on a page on my site it shows up in address bar as
    www.site.com/example.html
    How do I make it show up as www.site.com/example

    thanks,
    viktor



    Real Art Photography...where reality meets light.

  2. #2
    Join Date
    Jul 2006
    Location
    Canada
    Posts
    2,581
    Thanks
    13
    Thanked 28 Times in 28 Posts

    Default

    Make a folder called "example" and want you want to appear, will be called "index.html" in that folder.
    - Mike

  3. #3
    Join Date
    Dec 2004
    Posts
    83
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    thanx

  4. #4
    Join Date
    Dec 2004
    Location
    UK
    Posts
    2,358
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Quote Originally Posted by mburt
    Make a folder called "example" and want you want to appear, will be called "index.html" in that folder.
    In that event, the URI would be

      http://www.example.com/example/

    If the OP is intending to remove "extensions" on all files (or at least among some significant subset), then using directories isn't practical.

    I've mentioned two techniques in the past. A third is to use URL rewriting (on supporting servers), but that has only limited use as it can become difficult to determine which suffix should be applied when there are several to choose from. A fourth is type maps - another content negotiation mechanism. It doesn't produce extension-less URIs, but it does produce extension-neutral URIs by using a single form (typically .var, but any one will do).

    Mike

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
  •