Guidelines

How do I change the root of a subdomain?

How do I change the root of a subdomain?

Locate the domain to change the document root for under “Modify Addon Domain” or “Modify a Subdomain”. Click on the pencil icon next to the path, under the “Document Root” column. Enter the new document root for the domain, and click “Change”.

What is document root for subdomain?

The document root is the folder where the website files for a domain name are stored. Your addon and subdomain names will be rooted to their own folders inside public_html. After you create an addon domain or subdomain, you can find the document root inside cPanel by clicking on the Addon Domains or Subdomains icon.

How do I change the root of a document in WHM?

whm-change-document-root.md To properly edit an accounts DocumentRoot go to /var/cpanel/userdata/username/ (replace username with the actual cPanel username for the account), then edit the file domain.com (where domain.com is your primary domain name). Simply change both to the right path, then save the file.

How do I change the root of a document?

8 Answers

  1. To change Apache’s root directory, run: cd /etc/apache2/sites-available.
  2. Then open the 000-default.conf file using the command: nano 000-default.conf.
  3. Edit the DocumentRoot option: DocumentRoot /path/to/my/project.
  4. Then restart the apache server: sudo service apache2 restart.

How do I change the root file in cPanel?

To change the document root folder:

  1. Log in to cPanel.
  2. In the Domains section, click the Addon Domains or Subdomains icon, depending on which you’d like to modify.
  3. Locate the addon domain (or subdomain) you wish to modify.
  4. Click the pencil icon next to the current document root for the domain you wish to modify.

How do I change the root directory in cPanel?

In the account Dashboard, click cPanel Admin. In the cPanel Home page, click Domains and then select Addon Domains. Under Modify Addon Domain, next to the domain you want to change, click the pencil. Enter a new document root, starting at your home directory, and then click Change.

Which is the root folder in cPanel?

Document root aka cPanel root directory is the default directory in which your website files are stored. These files show up when you access the site via browser. When you create a domain in your cPanel/WHM server, the document root for that domain would be ‘/home/user/public_html’ directory by default.

How do I change document root in cPanel?

How do I change the document root in cPanel?

How do I change the root to CWP?

You can do it in following way: Open the file /usr/local/apache/conf/httpd. conf using any text editor (vi or nano)and go to the virtualhost section of the domain name for which you want to change the DocumentRoot. Save the file.

What is the root directory cPanel?

Changing Add-on Domain. Changing the document root for Add-on domains is easy. Simply log into your cPanel and navigate to: Domains >> Addon Domains. Next, edit the Add-on domain path. To do so, simply click the “Edit” icon next to the path, and type in your new path. It’s that simple!

How to change the document root for add-on domains?

Changing the document root for Add-on domains is easy. Simply log into your cPanel and navigate to: Domains >> Addon Domains. Next, edit the Add-on domain path. To do so, simply click the “Edit” icon next to the path, and type in your new path. It’s that simple! If you want to use a sub-domain for this application.

Where do I change the root path of a document?

out on the internet, on the web, but rather at the root (/) of your domain. but this idea is actually wrong and a bad assumption made by many new users. If you really must change it, then you can manually change it by editing the virtualhost of that domain in the httpd.conf and change the document root path there. Click to expand…

Can you configure DocumentRoot for the primary domain?

It’s a particular pain that cPanel doesn’t allow the user to configure DocumentRoot for the primary domain.

https://www.youtube.com/watch?v=EKfxQIUVMIE