InMotion Hosting Support Center

www vs. public folder


InMotionFans
n/a Points
Asked:
2014-05-12 5:38 pm EST

Hits: 45
I have been told by someone optimizing our site that our files should be in the www and not the public folder. I didnt know this was possible? He claims it is like having multiple copies of the same page.

You must login before you can ask a follow up question.

You must login before you can submit an answer.

OTHER ANSWERS

0

JacobIMH
9,968 Points
2014-05-12 5:49 pm EST
Hello, and thank you for your question.

It actually doesn't matter what folder you place your files in, because as you might have noticed, they are duplicated into the other folder automatically.

The server isn't actually storing two copies of the same files, instead the <code>www</code> file is simply a <strong>symbolic link</strong> to the main <code>/public_html</code> folder. These can also be called a <strong>symlink</strong>, or a <strong>soft link</strong>.

The <code>www</code> symbolic link could be deleted and the target directory of <code>/public_html</code> would remain unaffected. However if you deleted the <code>/public_html</code> directory, when you went to try to access the <code>www</code> symbolic link, it would cease to function because the target it was linking to no longer existed.

Hope that helps clear things up. Please let us know if you had any further questions at all!

- Jacob

You must login before you can post a comment about this answer.

Like this Question?

Need more Help?

Search

Ask the Community!

Get help with your questions from our community of like-minded hosting users and InMotion Hosting Staff.

Current Customers

Chat: Click to Chat Now E-mail: support@InMotionHosting.com
Call: 888-321-HOST (4678) Ticket: Submit a Support Ticket

Not a Customer?

Get web hosting from a company that is here to help. Sign up today!