".html" get rid of it this end of website name
Author: Jakub Skála
Visited 1795,
Followers 1,
Shared 0
Hello
I just created many website from website x5
It is www.rokaworks.cz
When i do subwebsite like rokaworks.cz/klice - it does nothing. I must enter into end of it ".html" I really hate it. How to do whole website to get rid of ".html" please????!!!!!
My provider of hosting is WEDOS
Posted on the
https://www.rokaworks.cz/klice seem not to be a subfolder. But there seem to be a page named klice.html in the root.
If you want a sub-website, you must make a sunfolder like klice.
You must then in that subfolder make a complete project. When you make a project in the subfolder, the project will have a page named index.html.
When you specify a url like https://www.rokaworks.cz/klice the system will look in that folder for a index-file it could be index.php or index.html.
So - you have to make a project and then upload that project to a subfolder (not the root)
"....ust make a sunfolder like klice....."
sunfolder >>>> subfolder
The questioner probably wants the .html extension to be removed from all pages.
WebSite X5 is not a CMS, why do people want to hide it?
In 2017 Johannes Müller said that this would not have any SEO advantages, has that changed?
exactly @Daniel !
@Jakub it's an SEO misconception
https://www.youtube.com/watch?v=xMIW3i37YeY
OH - I did not see that coming. I thought the question was about projects in subfolders.
I agree it does not make sense to remove the html - but if that is what you want Jakub, then take a look here:
https://stackoverflow.com/questions/5730092/how-to-remove-html-from-url
Author
Then people tell me this. What will get worse if I just get rid of .html ??
Writing page with ".html" is more difficult and look worse. Why it get worse to SEO? Anyway is there a way how to keep both of them? When write https://www.rokaworks.cz/klice - will redirect to https://www.rokaworks.cz/klice.html
?
Why anyway will this make it worse when keeping both ??? Sorry i dont understand SEO. I didnt care about SEO.WebsiteX5 do SEO itselfs or not? Im programmer of cars and IT i just know basisc about HTML/CSS and Csharp
Why is writing getting harder?
If you name the page "Klice", WebSite X5 automatically appends the ".html" at the end.
In SEO without ".html" there is no benefit and the browser doesn't care.
If visitors are bothered by ".html", then the website is too boring.
Author
No, it is just better remembering when I call someone who is total user and want my car services.
Is it too hard to understand please? :(
I just want simplicity and also want this feature what im asking. Will it affect SEO and will SEO be worse? How to have both of those things what i want? - just simple klice and klice.html ? Thank you
An example that needs to be tested and adapted to your own web space and server. There is no guarantee that it will work.
----- Content copied and translated from this German website -----
If you want to redirect a whole class of pages, then you have to work with wildcards, which can look like this, for example.
Content of the .htaccess file:
RewriteEngine On
RewriteCond %{REQUEST_URI} /(.*)\.html$
RewriteRule .* /%1 [R=301,L]
Very important: The instructions shown are only an example and have not been tested. We give general tips for search engine optimization here, but do not create or control any .htaccess files! In addition, we do not know the specific case and the implementation.
>> https://www.suchmaschinen-doktor.de/fragen/beitrag-158/dateiendung+aus+dem+url+entfernen.html
---------------
The experts would have to answer questions about .htaccess and they should have their web space with the same web hosting provider so that they can test adjustments.
Author
Ok and if I want just few sites that I want to have shorter name of page - then how? It has not to be whole website and subsites. Thank you
(because the manual which you sent is harder to apply. Im not programmer)
Own short URLs made easy with .htaccess
I did a quick search on Google and found a code for the .htaccess file, with which you can forward short URLs to long URLs on your own website.
----- Code for .htaccess file -----
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^pc$ computer-und-internet.html
RewriteRule ^car$ auto-und-verkehr.html
RewriteBase /bilder/
RewriteRule ^bg$ bg.jpg
RewriteRule ^se$ Seideneulchen.jpg
</IfModule>
---------------------------
A) Examples from my .htaccess code:
RewriteBase /
RewriteRule ^pc$ computer-und-internet.html
RewriteRule ^car$ auto-und-verkehr.html
Typed in browser and displayed in address bar > displayed page:
MyWebadress/pc > Webadress/computer-und-internet.html
MyWebadress/car > Webadress/auto-und-verkehr.html
-----
B) Examples from my .htaccess code:
RewriteBase /bilder/
RewriteRule ^bg$ bg.jpg
RewriteRule ^se$ Seideneulchen.jpg
Typed in browser and displayed in address bar > displayed page
MyWebadress/bg > Webadress/bilder/bg.jpg
MyWebadress/se > Webadress/bilder/Seideneulchen.jpg
---------------------------
As can be seen in the examples, there is a section for files that are in the root directory and a section for files that are in a subdirectory.
I tested the code for the .htaccess file on my web space and it works.
On your own web space, there is usually already a .htaccess file in the main directory, which is downloaded to the hard drive.
Then the code presented here is adapted to your own needs and added to the end of the existing code.
Then upload the .htaccess file back to the main directory of the web space.
Author
Hello, i didnt have time for it. So on, can someone describe, what is SUNFOLDER ? I dont see any "SUNFOLDER" im Maps. Just folder and website. So how to do that by the advice of "making sunfolder" instead of subfolder? I need some site named wihtout .html but still have it in subfolder because sites need to be apperad in menu also.
Or can i do a redirect? Something like entering rokaworks.cz/klice will redirect to klice.html
Author
sounds good but what If I make changes in website x5 program and program will upload this file to rewrite old one. I will have to write it manually again and again? Or it will remain the rest of manually code which i enter and it just rewrites or adds code to present htaccess file? Thank you
Author
ah sorry i see correction of mistake "sunfolder".
and read whole thing again. So only way is to manual edit. Because i want to have .html and also without .html
Question question is, if i must edit manually everytime.... :(
Author
Anyway, here is what is inside my htaccess file... Im little bit confused what to do with it
# WebSite X5 - Start Code [do not edit]
<IfModule mod_deflate.c>
SetOutputFilter DEFLATE
</IfModule>
# WebSite X5 - End Code
RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule (.*) https://%{SERVER_NAME}/$1 [R=301,L]
Header set Content-Security-Policy "upgrade-insecure-requests;
I'm not an htaccess expert, for specific questions the moderators or the htaccess experts have to answer.
I search my htaccess code via google on trustworthy websites and test it on a webspace to see if it works.
The WebSite X5 htaccess code should not be changed, it will be modified by WebSite X5 if necessary.
See it:
https://helpcenter.websitex5.com/en/post/255682
Author
Still no solution? I cant respect that some SEO or something similar must have .html
If you look on internet, i dont see any of them using this. Biggest websites like BBC, CNN, much of them not. So why I should have to? THere must be some easy trick how to do that, but how?
WebsiteX5 it selfs using some sites without it.... https://www.websitex5.com/en/resources/blog/ - for example
If you really want to get rid of the .html extension, you have to find an Htaccess expert who will then test it so that it really works.
Google search: htaccess .html remove
There are many results to test and if it doesn't work then go to an expert and pay them if they don't do it for a thank you.
Since it doesn't bother me, I'm not interested in spending hours searching for working code.