Forum: Ruby on Rails apache and subdomains

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
Scott W. (Guest)
on 2006-04-05 06:19
(Received via mailing list)
Hi,

I'm trying to get a subdomain to map to a controller.  For example:

blog.domain.com to point to /list

so in my virtual host I tried:

    RewriteEngine On
    RewriteCond %{HTTP_HOST} ^blog.localhost$
    RewriteCond %{REQUEST_URI} !^/blog/
    RewriteRule ^(.*)$ /blog/$1

but it just goes to the root of my rails app.  any ideas?

scott.


----------------------------------------------------------------------------------------------------
What's an Intel chip doing in a Mac? A whole lor more that it's ever
done in a PC.

My Digital Life - http://scottwalter.com/blog
Pro:Blog - http://scottwalter.com/problog
This topic is locked and can not be replied to.