-6

Like the title says I want to visit my webpage without typing .html after the webadres. So for example I have to type this at the moment: www.webadres.com/webpage.html Now I want to change that into www.webadres.com/webpage

I've already tried some things like deleting the .html extension on the end of my file but that (of course) doesn't work.

I see I missed something: I don't really understand it but I got a folder (called "cgi-bin") with a .htacces file. In the .htacces file is the following text:

Options -Indexes +ExecCGI AddHandler cgi-script .cgi .pl

I want a webpage like this

www.example.com/webpage

Instead of

www.example.com/webpage.html

I didn't know about all the server side technologies but now it seems I have Apache.

If it didn't worked out you could also check out these:
How to remove .html from URL
ReWrite rule to add .html extension

Community
  • 1
  • 1
TheNLGhost
  • 1
  • 1
  • 4

1 Answers1

-2

create a htaccess file which has the name of .htaccess, then place the following code

RewriteEngine on
RewriteRule ^yourPage$ yourPage.html [NC,L]
Tamás
  • 950
  • 2
  • 10
  • 29