If you have a customer that setup a subdomain and they used the default location (/public_html/subdomain/), but they have decided that they want to move that outside of the public_html folder, you need to do the following.
- Open /var/cpanel/userdata/$USERNAME/$SUB.DOMAIN.COM in your favorite text editor
- Change the path on the “documentroot” line to the path that the customer wants their site to point to.
- run
/scripts/rebuildhttpdconf
- Restart apache.