I am using this rule for main site and subdomain (both have their own .htaccess)
RewriteRule ^(.*)-(.*).html /moredetails.php?pid=$2
and it is working fine for both (www.example.com and subdomain.example.com)
but when I access subdomain as www.example.com/subdomain then the htacess inside subdomain folder is not working and it executing root .htaccess
Can anyone tell exactly what the problem is and how can it be sorted out?