Skip to main content

Subdomain inside public_html

Comments

4 comments

  • cPanelMichael
    Hello, You will need to update your custom rewrite rules in the .htaccess file under the public_html directory so they do not apply the sub-directories beneath it, or setup a rule in the .htaccess file in the subdomain's document root that ignores the .htaccess entries in the parent directory. You can find discussion of the specific rules to use on a URL such as this: .htaccess mod_rewrite - how to exclude directory from rewrite rule Thank you.
    0
  • toplisek
    Is there also php INI settings that it prevents such mode without HTACCESS?
    0
  • cPanelMichael
    Is there also php INI settings that it prevents such mode?

    Hello, There are no PHP settings to change in this case since the rules are coming from Apache's Mod_Rewrite module. Thank you.
    0
  • toplisek
    As I understand it will be possible to place rewrite inside public_htm folder but dangerous as it will be consequence for the subdomain and main domain. If I have SUBdomain like example.mymaindomain.com Which rule inside htaccess is the best as I do not like to create a loop that will also time out? Example inside SUBdomain folder which will be without any loop that will also time out: RewriteEngine On RewriteRule ^
    0

Please sign in to leave a comment.