subdomains and 403 forbidden

Status
Not open for further replies.

acpcrio3

New Member
Messages
7
Reaction score
0
Points
1
i made a subdomain but i get 403 forbidden. how do i fix this?


hLQIdw2.png



i made a subdomain but i get 403 forbidden. how do i fix this?


>created a subdomain
>"0.ac.pcriot.com"
>open 0.ac.pcriot.com
>forbidden
>why

pic related. i combined the page with the subdomain and the 403 forbidden error i get it to work.- i added the big red text part. if that isn't obvious.

also created a "/1" directory with an "index.htm" and ".htaccess" file there. but i still get the "403 forbidden" error.

my "index.htm" page works. and i edited the ".htaccess" file in a text-editor -
so that going to "ac.pcriot.com" redirects to "ac.pcriot.com/index.htm" - without showing it.

i did the same in the "/0" and "/1" directories. but still get the "403 forbidden" error.

so i guess the question is also "i made a subdirectory but i get 403 forbidden. how do i fix this?". - an ".htm" file in a subdirectory.

it probably has to do with some setting that doesn't let anyone view ".htm" pages outside of "/public_html" or any of its subdirectories.

i attempted to look up information how to fix this.

but i can't find any information on it. it usually involves them buying a domain and attempting to redirect that way. i'm using free x10hosting for now.

i know it must be simple. i just can't find it.

it would be nice to have help instead of being told to look it up.

i apologize in advance.

thank you.


also my site is basically an experimental site that i use to make and post some stuff.

i would appreciate it if an admin or mod or support etc. don't correct anything. tho help is appreciated. i would like to learn how correct this myself.


if you have any questions, comments, or suggestions on this - or what to do - feel free to post.


also this is somewhat off-topic but if there's an alternate way to make subdomains - without it using up my subdomain limit - then that'd be nice, too.


as well it'd be nice to be able to delete threads.

it'd also be nice to have all of the options in "bbcode" mode. without having to use preview-mode.

it'd also be nice to optionally add bbcode or stop it from being added automatically.

also i sort of didn't immediately realize that my name was automatically my login name for my uploading account.

i'd delete and make an alternate account for forum posting in retrospect. - if i could.


i also went to irc.x10hosting.com . but it doesn't look like it's around anymore. something everyone can forget vs. around prominently forever. oh well...


also i added links and pictures. i know how you love them so much.


links.

http://ac.pcriot.com

http://0.ac.pcriot.com

http://ac.pcriot.com/0

http://ac.pcriot.com/1


pictures. at the top.


edit:

dropbox no longer direct links. apparently. not for free. apparently. that's sad.

imgur it is.

tho i miss dropbox. since dropbox had the original file-name. - instead of a re-named file-name.


too long; didn't read: i made a subdomain but i get 403 forbidden. how do i fix this?


thank you.
 
Last edited:

lylex10h

Active Member
Messages
982
Reaction score
71
Points
28
Do you have a .htaccess in /public_html ? If so, try renaming it to .htaccess.txt and seeing if that makes a difference.
 

acpcrio3

New Member
Messages
7
Reaction score
0
Points
1
Do you have a .htaccess in /public_html ? If so, try renaming it to .htaccess.txt and seeing if that makes a difference.

yeah. it didn't work.

here's what's in my ".htaccess" file. - and now ".htaccess.txt" file.

Code:
DirectoryIndex index.htm index.html

RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^([^\.]+)$ $1.htm [NC,L]

both the ".htaccess" file and the ".htaccess.txt" file are forbidden as well. - just saying.

still not working.

but thank you.
 

acpcrio3

New Member
Messages
7
Reaction score
0
Points
1
i figured it out.

i know what i have to do.


Do you have a .htaccess in /public_html ? If so, try renaming it to .htaccess.txt and seeing if that makes a difference.

you're right.

it kept going to the directory by itself. - without it being redirected to anything. - tho i would still like to know how to give others access anyway period.

i have to put separate ".htaccess" files in the directories i want the sub-domain to be in.

Code:
DirectoryIndex index.htm

RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^([^\.]+)$ $1.htm [NC,L]

then the directory relocates to the file without having to enter full file-name.

the following leads to "403 forbidden". - because it's attempting to go to the directory - without redirecting to any file.

Code:
DirectoryIndex index.htm

the following leads to "404 not found". - because you -can- go to the directory. but it's looking for "0.htm" and "1.htm". - not "index.htm".

Code:
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^([^\.]+)$ $1.htm [NC,L]

again. both combined work. -
if you want to use "index.htm". - but making "0.htm", "1.htm", "[directory].htm" also works - without "DirectoryIndex". -
but it redirects to "0.htm" etc. in the "public_html" directory - not the "public_html" sub-directory. - apparently. - so "DirectoryIndex" may be for the best.

Code:
DirectoryIndex index.htm

RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^([^\.]+)$ $1.htm [NC,L]

that's what i see. if that's wrong. then tell me.


edit:

also if i do "DirectoryIndex anything.htm" - without "anything.htm" being there - then it actually displays a directory index of your site. -
i guess it's because "DirectoryIndex" doesn't find the file. - so it defaults to an actual directory index.
just saying.


seems to be working now.

i'm happy that this can help others with similar issues. couldn't find any answers when looking it up.

i appreciate your help.

thank you.


too long; didn't read: it's working now. - apparently.


thank you.
 
Last edited:
Status
Not open for further replies.
Top