example: http://www.yahoo.com/games.html I want it to be: http://www.yahoo.com/games How can I remove the extension?
Google is god. But you should know what to search. In your case, a bit of code in the .htaccess will give you the solution. Visit this for more: http://corz.org/serv/tricks/htaccess2.php
But i want to remove index.html not only .html extension? How to remove this index.html from URL .. like domain.c0m/index.html to d0main.c0m/
strange, usually if you put the index.html in your server public_html or www directory then the accessible path for your site is http://www.yourdomain.com if this is not the case then you should check the .htaccess or contact your system admin
When i use extensionless "urls" they are actually index files each in their own folder. the url end with a trailing/ everytime.....
I think extensionless url is not possible to view in apache (assuming you are using apache) but if its viewing the index of your folder then I believe you should check your apache configuration to avoid prying eyes get your file listing.
Let's say you wanted a page called Videos, but you wanted to type in example.com/videos instead of www.example.com/videos.html. This is what you would do. You would create a folder in your website called videos, and then put a .htm file in that folder. Now when ever someone types in www.example.com/videos , it will display that .htm page you put in the folder. I hope this helps. BTW I just found this out with my own site. http://www.liquidlettuce.com/puffnpluky76 Please check out my site.
Rename the file to index.html and put in the folder domain.com/games/ But remember to share your games page with slash ending after games "domain.com/games/" This is very important.
.htaccess file with this in Options +MultiViews Then when you make links you can use the URL without the extension and it will work fine, this works great if your running php aswell. I normally also add in a 301 so requests for domain.com are sent to www.domain.com aswell so my basic .htaccess file normally contains atleast. Options +MultiViews RewriteEngine on RewriteCond %{HTTP_HOST} ^([^.]+\.co.uk) [NC] RewriteRule (.*) http://www.%1/$1 [R=301,L] Code (markup): Example of a site I am currently working on to show you it works. http://www.slaughter-house.co.uk/sh/hair
Like johneva said, turn on MultiViews MultiViews are seriously the way forward because they automate a lot of this stuff. For example, if you gzipped your file /something.html.gz you can access it using /something It really takes the hassle out when using mixed extensions.
create a new folder in your FTP directory and call it anything you want e.g yoursite.com/games and in that folder make your index.html and your done
Thing is thats not really the correct way to do it, yes it works but makes alot of work for no reason and also makes a mess of your directory system. That way means you have to make a new folder for every file you have for the site and rename all files to index.html. Really dont get why anybody would use that way its just confusing messy and makes extra work. Doing it with .htaccess file means making 1 file with 1 line of code in, then uploading it to your root, done, no file needs file extensions.
Google 'htaccess mod_rewrite search engine friendly URLs' .htaccess is the file you will create/modify. mod_rewrite is the function you will be applying inside of .htaccess to create your search engine friendly (SEF) page URL's. You can create dynamic matching patterns or static rules for your URL's.