mbleigh / subdomain-fu

A new plugin approach to attempting to solve the usage of subdomains in linking and routing in Rails projects.
http://rdoc.info/projects/mbleigh/subdomain-fu
Other
586 stars 118 forks source link

miss routing ajax request #15

Open old-grrt opened 14 years ago

old-grrt commented 14 years ago

XMLHttpRequests are being miss routing, any idea way?

GET http://sd.mydomain.com/categories/1 routed properly. (SD::CategoriesController < SDApplicationController)

new Ajax.Request('http://sd.mydomain.com/categories/1', {asynchronous:true, evalScripts:true, method:'get'... routed to ApplicationController#index

Also I got

ActionController::MethodNotAllowed (Only get, put, and delete requests are allowed.): which does not make much sense since its set as get request.

My routes

map.subdomain :sd do |sd| sd.resources :categories, :controller => "sd/categories" end map.resource :categories

Am i doing something wrong, is it a bug or a constraint?

I appreciate any insights

subdomain-fu 0.5.4 rails 2.3.8 ruby 1.8.7