In the workplace, I have a page defined using the start#index route.
This works as expected.
Now some scanners are viewing the page for things like /crossdomain.xml , and this will start controller and it will try to return the XML view.
Unfortunately, I did not define an XML representation or template or anything like that, and thus error messages are generated (via eMail, so this is pretty annoying):
[Exception] start#index (ActionView::MissingTemplate) "Missing template start/index with {:handlers=>[:rjs, :rhtml, :builder, :rxml, :erb], :formats=>[:xml], :locale=>[:crossdomain, :en]} in view paths
So, I think there are 2 options:
- Disable all XML / JSON in this application and display the 404 page by default.
- Create a dummy XML view.
I would prefer the first choice, but I'm not sure how this can be done? Thanks for the suggestions or the best practice link.
EDIT , as requested, the output of rake routes . Do I see some error in the second last line that I assume?
new_editor_session GET /editors/sign_in(.:format) {:action=>"new", :controller=>"devise/sessions"} editor_session POST /editors/sign_in(.:format) {:action=>"create", :controller=>"devise/sessions"} destroy_editor_session GET /editors/sign_out(.:format) {:action=>"destroy", :controller=>"devise/sessions"} /auth/:provider/callback(.:format) {:action=>"create", :controller=>"sessions"} signout /signout(.:format) {:action=>"destroy", :controller=>"sessions"} photo_of_week_submissions GET (/:locale)/submissions/photo_of_week(.:format) {:action=>"photo_of_week", :controller=>"submissions"} select_photo_of_week_submission GET (/:locale)/submissions/:id/select_photo_of_week(.:format) {:action=>"select_photo_of_week", :controller=>"submissions"} accept_submission GET (/:locale)/submissions/:id/accept(.:format) {:action=>"accept", :controller=>"submissions"} submissions GET (/:locale)/submissions(.:format) {:action=>"index", :controller=>"submissions"} POST (/:locale)/submissions(.:format) {:action=>"create", :controller=>"submissions"} new_submission GET (/:locale)/submissions/new(.:format) {:action=>"new", :controller=>"submissions"} edit_submission GET (/:locale)/submissions/:id/edit(.:format) {:action=>"edit", :controller=>"submissions"} submission GET (/:locale)/submissions/:id(.:format) {:action=>"show", :controller=>"submissions"} PUT (/:locale)/submissions/:id(.:format) {:action=>"update", :controller=>"submissions"} DELETE (/:locale)/submissions/:id(.:format) {:action=>"destroy", :controller=>"submissions"} login (/:locale)/login(.:format) {:to=>