I have domain (http://example.com) where the contents of the main domain is placed inside public_html and my subdomain (eg.example.com) where the contents of that subdomain is placed in a separate folder outside public_html.
I want to redirect the subdomain to main domain index.php without altering the browsing url. How to solve this problem.