Thanks for the advice; it worked fine pre-2.3 though. I added "Mime::Type.register_alias "text/javascript", :iphonejs" to mime_types.rb and put "format.iphonejs" in the respond_to block, but now I get a 406 Not Acceptable error. Am I doing it wrong?
On Apr 17, 9:13 am, Marnen Laibow-Koser <rails-mailing-l...@andreas- s.net> wrote: > Andrew wrote: > > [...] > > > There are no errors whatsoever, however the rjs doesn't get executed > > at all, even with Firebug showing the js in the response. Surely > > someone can help with this? > > The problem would appear to be that you've got youriphonemime-type > defined as text/html. This means that even though Rails is correctly > processing the RJS file, it is telling the browser that the file is > HTML, not JavaScript. You'll need a separate type (iphone_js or > something) defined as text/javascript. > > RJS is evil anyway. :) > > Best, > -- > Marnen Laibow-Koserhttp://www.marnen.org > [email protected] > -- > 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 [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---

