8
votes
Best form for URLs: file-name.html or /file-name/
You have several options for removing extensions. You don't have to create a directory for each file.
Use Apache's mod_negotiation with multiviews. You enable it with Options +multiviews in your ....
7
votes
Accepted
Redirect from index.html to its directory using .htaccess?
You can do this using mod_rewrite near the top of your .htaccess file. In its simplest form this would be something like:
RewriteEngine On
# Remove "index.html"
RewriteRule (.*)index\.html$ ...
4
votes
Best form for URLs: file-name.html or /file-name/
A document that is not often read but should be:
https://www.w3.org/Provider/Style/URI.html "Cool URIs don't change"
To extract the parts relevant to your question:
So what should I do? ...
3
votes
500 Server Error: Cannot serve directory: No matching directory index
So I finally reached out and contacted GoDaddy support. After an hour, we determined there might be an error in my code. And after a little bit of digging and testing with some basic files, he was ...
3
votes
Best form for URLs: file-name.html or /file-name/
"(file extensions) can reveal the underlying technology of the website making it very slightly more vulnerable to hackers" is humorous. It is trivial to find out the underlying technology ...
3
votes
Accepted
Is it possible to display the path with an Apache index listing with a custom header?
I think the "Apache-way" would be to use Server-Side-Includes (SSI) (mod_includes). There does not appear to be a way to access this information with mod_autoindex, nor to output arbitrary ...
2
votes
Is it possible to display the path with an Apache index listing with a custom header?
Since you are using a custom header, adding a small piece of JavaScript to the header file should help.
For example, below JS code in the custom header will modify the h1 tag (custom defined) to show ...
2
votes
How does the base URL of a website show the contents of home.php?
The home page for a website is served based on the configuration of the web server that hosts it.
Typically, the default setting would be that on attempting to reach the root of any directory, the ...
2
votes
Best form for URLs: file-name.html or /file-name/
The suggestion is almost purely cosmetic; Google doesn't care. I guess if you decided to blaze your own trail and make all of your page extensions .jpg then you can deal with the fallout of such a ...
1
vote
Would Google penalize home.php and index.html on one root?
Your server will be set up to serve default index page which may be default.html, index.html, index.php or something else. You can call your other pages what you like, though the extension may be ...
1
vote
500 Server Error: Cannot serve directory: No matching directory index
It seems that in the public_html folder there is no index.html or index.php (or other).
Are you sure after the upload there is at least a file name index.php? Can you check in ftp or file manager and ...
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
directory-index × 18htaccess × 5
apache × 5
seo × 3
url × 3
webserver × 3
redirects × 2
php × 2
301-redirect × 2
mod-rewrite × 2
nginx × 2
homepage × 2
subdirectory × 2
google × 1
google-search × 1
html × 1
search-engine-indexing × 1
web-development × 1
canonical-url × 1
server × 1
search × 1
browsers × 1
iis × 1
web-applications × 1
virtualhost × 1