Skip to main content

Proper file structure for new account?

Comments

3 comments

  • cPanelLauren
    Hi @Pippab By default the document root of your site (where your site data goes) is /home/$user/public_html/ this is where you should store your site data. Based on the image you provided it looks like you put the folder containing the site data directly into home. I would move the data inside the folder into public_html. As for the subdomains when you go to cPanel>>Domains>>Subdomains the directory listed under Document root for the domain should be where the site related data is added.
    In regards to permissions. With my limited understanding, I wish to have full access but I wish visitors to only be able to read the pages/data on the website. To this end I have set permissions for my home domain directory and sub-domain directory & files as 0744. This may well be wrong but my understanding of the subject is limited so suggestions most welcome.

    In general, all directories will have permissions of 755 and files of 644 and this should work for you without making modifications in most cases
    In addition, whilst creating my sub-domain & moving files about, I may have inadvertently deleted some files which were automatically generated when the account was opened and for which I failed to understand the significance of.

    Are you aware of which files specifically you removed? You might want to try and start over - recreate the account then re-add your data if you're unsure.
    0
  • Pippab
    Thanks for the info. I altered the permissions as suggested & moved the site data into public.html & all appears to be resolved :-D.
    0
  • cPanelLauren
    Hi, I'm glad to hear that the issue is resolved, you're most welcome, we're happy to have been able to help!
    0

Please sign in to leave a comment.