FRIHOST FORUMS SEARCH FAQ TOS BLOGS COMPETITIONS
You are invited to Log in or Register a free Frihost Account!


Showing Directory as 403 Forbidden





ankurthakur
Hello Guyz,

I wish that I am posting it in right section.

There is a Path in my website where several PHP Files are located.

I had added a .htaccess file in that Dir to change the Content Type to text/plain of all the php files inside that Dir using this :
Code:
# Added UTF-8 Charset for Hindi
AddCharset UTF-8 .php

# Added Language 2 char COde
AddLanguage hi .php

# Added the Content Type
AddType text/plain .php

After this, it is used to behave like Trunk system like in Sourceforge.net, i.e, view Source of PHP Files (as my project is open source)

This is normally working on my previous host. After I've moved to this host, its just giving me 403 on viewing that dir.

Also, the PHP Files which should be shown as text/plain and the source should be shown, but they are getting compiled.

The path is http://ankurthakur.in/locale/Hindi/

I've nothing else than that code in my htaccess and I am sure that no other htaccess in Up Folder of that Dir is conflicting.

So Please help me.

Thank You
Ankur
Bondings
If you take a look at the error log, it show:
Quote:
Directory index forbidden by Options directive: /home/ankurtha/domains/ankurthakur.in/public_html/locale/Hindi/

You need some specific .htaccess directive to show the files if there is no index.php/index.html present, otherwise it will give that error.

I added:
Code:
Options +Indexes

to the .htaccess file and now it shows the files.

About how to stop executing .php files, I didn't find a working way to do it as you wish. The last line only makes the php files be served as text files - however you first need to stop them from executing as php files and that directive I don't know.
Related topics
403 Forbidden Error
403 Forbidden verwijderen
403 Forbidden
WP (blog) xmlrpc.php gives a "403 forbidden", no m
403 forbidden? Please help.
403 forbidden
Homegrown GFX (!!MODS PLEASE LOCK! OLD THREAD!!)
Forbidden?
403 Forbidden
Directory acces forbidden
My Blog: 403 Forbidden
to show "403 Forbidden" Directories
I get 403 Forbidden when i open my site in the browser
403 Forbidden
Reply to topic    Frihost Forum Index -> Support and Web Hosting -> Frihost Support

FRIHOST HOME | FAQ | TOS | ABOUT US | CONTACT US | SITE MAP
© 2005-2011 Frihost, forums powered by phpBB.