First, I've read through every post on here regarding wildcard dns support, directory forwarding, etc and haven't found anything I've been able to make work yet.

I'm trying to get anything2.anything1.mysite.com to pull from mysite.com/anything1/anything2 etc (as in keep the visable path anything1.mysite.com). I thought I could simply use wildcard dns support and quick mod rewrite to make it work but no luck thus far. I've got wildcards enabled and I've tried out a number of mod_rewrite codes, this is what I'm currently running:

# first check if it's a directory
RewriteCond %{HTTP_HOST} ^([^\.]+)\.coreysmith.info$ [NC]
RewriteCond %{DOCUMENT_ROOT}/%1/ -d
RewriteCond %1__%{REQUEST_URI} !^([^_]+)__/\1
RewriteRule .* /%1%{REQUEST_URI} [QSA,L]

# .html
RewriteCond %{HTTP_HOST} ^([^\.]+)\.coreysmith.info$ [NC]
RewriteCond %{DOCUMENT_ROOT}/%1.html -f
RewriteRule ^$ /%1.html [QSA,L]

I'm not very good with mod_rewrite but I'm assuming the issue lies somewhere in the current rewrite rules for drupal's default install or with the pathauto/path modules.

Does anyone have a working solution or know how to correct this issue? I'm sure others would love to have a solution for this as well.

Thanks,
Todd Dickerson

Comments

drupal777’s picture

.... and apache's mod_rewrite is almost never dealt with on an indepth basis. I've hung around the newsgroup alt.apache.configuration, however, and there are a couple of people there that enjoy digging deep into what people around here sometimes refer to as "voodoo".

The newsgroup folks are not likely to be too keen on Drupal specific issues, though.

If you can cast your question in the abstract, rather than in Drupal-ese, you are pretty much guaranteed a good response over there.

I'm not capable of adding anything substantive, so I won't even try.

But I'd love to see the result you end up with.