Hello, I really need some input. I transferred a site last night, one that had two subdomains. Everything was coming up fine. Today, one of the subdomains is redirecting to a folder under the main directory. The other one is not. I tried removing it through cpanel. That, oddly enough, did not remove the files. So I removed the files via ftp. Then I created the subdomain again. Still has the same redirect issue.
My other subdomain works fine. I can access it as subdomain.domain.com. But the second subdomain redirects automatically from subdomain.domain.com to domain.com/subdomain.
My .htaccess is below. This .htaccess has worked fine for a year on another server. And my other subdomain works fine on this server (both on the same domain). So I don't believe it is a .htaccess problem like tech support suggests. Anyone have any ideas what else it could be?
My other subdomain works fine. I can access it as subdomain.domain.com. But the second subdomain redirects automatically from subdomain.domain.com to domain.com/subdomain.
My .htaccess is below. This .htaccess has worked fine for a year on another server. And my other subdomain works fine on this server (both on the same domain). So I don't believe it is a .htaccess problem like tech support suggests. Anyone have any ideas what else it could be?
Code:
#Redirect direct client requests for /index.php or /index.shtml in
# any subdirectory back to [URL="http://www.example.com/"]www.example.com/[/URL]
RewriteCond %{ENV:REDIRECT_STATUS} ^$
RewriteRule ^(.+/)?index\.(php|shtml)$ [URL]http://www.example.com/[/URL] [R=301,L]
#
# Redirect direct client requests for /subdir/ back to [URL="http://www.example.com/"]www.example.com/[/URL]
RewriteCond %{ENV:REDIRECT_STATUS} ^$
RewriteRule ^subdir(/(.*))?$ [URL]http://www.example.com/$2[/URL] [R=301,L]
#
# Redirect non-canonical hostname to canonical host
RewriteCond %{HTTP_HOST} !^www\.example\.com$ [NC]
RewriteRule ^(.*)$ [URL]http://www.example.com/$1[/URL] [R=301,L]
#
# Rewrite Web root directory requests to /subdir
RewriteRule !^subdir(/.*)?$ /subdir%{REQUEST_URI} [QSA,L]