i have a situation where i have a billing software package in a sub folder of a wordpress site domain.com/billing and the cookies are conflicting when you login to the billing software. the billing software uses domain.com for its cookies and according to the developer cant be changed easily.
wordpress also used domain.com but i can change it to use www.domain.com
and for the most part this solved the cookie login issue. unless someone types in www.domain.com/billing
my wordpress is configured to use www.domain.com and i have this rewrite in the root folder .htaccess.
<IfModule mod_rewrite.c>
Options +FollowSymLinks
Options +Indexes
RewriteEngine On
RewriteBase /
RewriteCond %{HTTP_HOST} ^domain\.com$
RewriteRule ^(.*)$ http://www.domain.com/$1 [R=301,L]
</IfModule>
this works fine.
in the domain.com/billing folder i would like to do the opposite and remove the www. to make sure the url is correct.
i have tried different variations of the above with out success. i understand the .htaccess is recursive so i am not sure if this should be in the root htaccess file or in an additional .htaccess file in domain.com/billing
thank you in advance for any suggestions on how to get this working.
Sean