403 Forbidden when accessing folder with index.html


#1

Hello, I built a website and had to move the hosting here because hostinger’s free servers had ran out of Hard drive space (Probably intentional)

Anyway, the new website I wrote has an issue on this host.

Normally when you point to a folder with an index.html the host displays the index.html - This is not the case here.
Instead a 403 is given.
If I access the index.html file directly it functions as intended.

Example:
https://djrapitops.000webhostapp.com/music/ - 403
Same address with index.html in the end works fine (“New users can only post one link”)

I want to use the folder/index.html system to remove the .html requirement and to have a cleaner folder structure.
How can I fix the 403?


#2

Hi @Rapitops!

All problems have been fixed.

Please clear your browser cache and try again.


#3

Thank you very much :slight_smile:
Nice to wake up to all problems being fixed.


#4

I managed to break it again by changing the .htaccess without downloading the one on the server first.
What changes did you add to it to make it work?


#5

This line was causing the error
RewriteRule ^([^.]+)$ $1.html [NC,L]
I have fixed the error :slight_smile:


#6

Now it is giving me 500 on all pages :frowning:

Fixed by removing .htaccess file