About the creation of a subdomain on cPanel, do you advise me to create the directory inside public_html or outside?
How to decide where?
Create the directory for your subdomains & addon domains outside the Public_html folder is the safest one because its only the solution for the directories got deleted accidentally while updating the primary domain.
Regards,
Sathya.
Please read this carefully
Hi, you can create the subdomain with the public_html directory if you want your main website files to be viewed by the subdomain. But, if you will delete the subdomain, the public_html directory will be deleted. So, using your subdomain in a directory different than public_html is safer.
Secondly, you will need to configure the DNS of the domain if it is not configured automatically, which will result in the subdomain not working.
If in case the subdomain created is not working,
Go to the DNS section of your domain, and create a new CNAME record mostly like this.
Host IP (Points to) TTL
(yoursubdomain with/without domain) # 600
Also, if you have any trouble with cPanel, you should ask about it at https://forums.cpanel.net for more assistance.
Thanks.
Related
We have domain.com as the main domain with some different apps in it.
We have prestashop.domain.com as a subdomain which is also a subfolder of root folder in the server public_html folder and contains prestashop installation core.
We want to have multiple shops with the help of prestashop multistore in this way:
someshop.domain.com
anothershop.domain.com
Is it even possible?
Because in the documents it says it is possible and it is done automatically by prestashop.
Check this : https://doc.prestashop.com/display/PS17/Setting+a+shop's+URL#space-menu-link-content
But it is not working for me anyway. I have been trying a lot of cpanel stuff.
It only works in this way:
prestashop.domain.com/someshop
prestashop.domain.com/anothershop
in such configuration Prestashop is responsible to route requests to both subdomains with a unique .htaccess placed in root directory and , of course, a unique installation.
So you have to ensure to configure both subdomains document root in cPanel towards the same server physical path where Prestashop resides.
Then, make sure to set the physical URI to "/" for both shops in the multistore configuration, this should do the trick.
Hi I have been learning how to design a website and it went ok but i tested it on localhost and everything is working as it should but i have been having some trouble with functionality when i have uploaded my files to my hosting provider Arvixe.
I've been trying to learn how to structure my website properly in the domain folders but i can't work out how it should be properly organised.
I have a Parent website, and subdomains that need to go together so for example -
Parentwebsite.com
Subdomain1.Parentwebsite.com
Subdomain2.Parentwebsite.com
Subdomain3.Parentwebsite.com
On my locahost test server i just created the websites individually and put them under the htdocs folder in XAMPP. However the folder structure for the Arvixe hosting is a lot different - it currently looks like this:
http://imgur.com/brqSp9W
Am i laying out my folders correctly?
And also if i have PHP scripts for the website are they better suited to go into their own folder inside public html? Or they better suited to go directly into the public html folder?
Thanks in advance for any help :)
Your web host is using cPanel and it has typical directory structure which is quite different compared to your Local XAMPP environment.
Here's how cPanel stores the website files.
/home/cPanel-user/public_html ==> Main domain
/home/cPanel-user/public_html/addon-domain-directory ==> Addon domain
/home/cPanel-user/public_html/subdomain-directory ==> Sub-domain
To make your website accessible via web, upload your web content files to
/home/cPanel-user/public_html directory.
When you add a addon domain from cPanel, its web files will be stored at;
/home/cPanel-user/public_html/addon-domain-directory
When you add subdomain, its web files will be stored at;
/home/cPanel-user/public_html/subdomain-directory
I had two domains on one hosting account, managed by cpanel. During the second domain installation I opted to use root folder outside public_html because the second site was going to have independent ftp administration not related to the one of the first domain at all. So I didn't want the files of the second site to be accessible in public_html.
That worked pretty well until the second domain expired and wasn't going to be renewed. However, despite website isn't public already, I want to have web access on it for testing and other purposes but it seems like cpanel doesn't allow subdomain directories outside public_html.
Is there a way, to achieve that without having to migrate all subdomain files to public_html and thus - making them accessible for the administrators on the main domain (which is undesired)?
One way you can do this is by having two cPanel hosting accounts:
- domain.com
- subdomain.domain.com
In case the hosting accounts are in different servers, you should make an A record subdomain.domain.com pointing to the server that specific hosting account is created.
By doing that, you will have two separated environments, usernames, passwords and databases will be different from each other. The hosting account domain.com won't be able to see the files and manage anything on subdomain.domain.com. The same applies vice-versa.
create folder out side www as for example hello. and in cpanel/subdomains point that such as ../hello in Document Root
What I need is a web server hosting just for saving large files on it and share it online, so today I downloaded XAMPP Control Panel V3.2.1 as I read on a topic that it can help me.
Actually, I don't have enough knowledge about XAMPP, can I use it to upload files with normal domain(like: www.mydoamin.com/myfile)?, how can I connect the server I build with a domain after purchasing it? and how can I upload files to this domain.
Till now I done all the needed setup, and here's what I get when I start the application:
Also I can use the "MySQL" in the webpage after log-in, and here's how the page looks like:
Is there any recommendation for other application that helps me uploading files to my own domain/server and share it, if this one isn't for these stuff?
XAMPP is software bundle containing cross OS solutions (X) for webserver Apache (A), MySQL database (M), and server-side language PHP (P) and Perl (P).
If you got a domain you need to redirect it to IP on which this XAMPP server works. To do it call/mail your domain registrator (a company that sold you a domain) and ask about it. It involves DNS (Domain Name Server) configuration - ask them how to change DNS to direct it to your XAMPP server.
PS To add files go to htdocs direcotry in your XAMPP instalation or whatever you defined to store files (and websites) and drop your files in there.
As I can see you are not experienced in that kind of things so maybe ask company that sold you a domain name about "shared hosting"? It's preconfigured ready to go server where you send files over FTP
We have a webserver managed by our department and each of us have a personal web space url like:
http://students.university.edu/myusername (1)
we can access to our webfiles folder and edit index.html and have other data. I think we also have php server installed with our department webserver so we can also make a php website.
But I want to setup a webserver on my machine in my lab and redirect any access to my personal webspace above (1) from any external client anywhere around the world to my webserver on my local machine. In other words I don't want to use the webserver managed by our department IT because basically I need access to my files on my computer. And as you may notice my machine's ip is local in our infrastructure and invisible from outside. Is there any suggestions?
found this article that says in the .htacces file on your server, add
order deny,allow
deny from all
allow from 192.168.0.0/24
that should block everyone but the people on ips 192.168.0.0 through 192.168.0.24
of course if u dont have the .htacces file, which you should, you have to create the file in text editor, just calling it .htaccess with no extension
hope this helps