newband.mysite.net

if thats the URL u want, then tld_size should be 1.

newband.localhost:3000

if thats the URL you're developing with, then tld_size should be 0.

tld_size = (number of dots in URL) - 1    (to put it crudely)

On Apr 4, 3:33 am, Petr Bobek <rails-mailing-l...@andreas-s.net>
wrote:
> Hi all,
>
> I am bit stuck with subdomain_fu plugin. I want to create a new
> subdomain for newcomers. e.g. newband.mysite.net
>
> I set the tld_sizes:
> SubdomainFu.tld_sizes = {:development => 0,
>                          :test => 0,
>                          :production => 2}
>
> my routes.rb:
>
>   map.resources :bands
>   map.band_root '', :controller => 'bands',
>           :action => 'show',
>         :conditions => { :subdomain => /.+/ }
>
> bands controller:
>   def show
>     @current_band = Band.find_by_subdomain(current_subdomain)
>   end
>
> I always end up with "CANT FIND THE PAGE" error.
> ANy help would be most welcome.
>
> P.
> --
> Posted viahttp://www.ruby-forum.com/.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com
To unsubscribe from this group, send email to 
rubyonrails-talk+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to