If you need "Umlaute" in Ruby on Rails you can use the following filter
in the ApplicationController:
class ApplicationController < ActionController::Base
before_filter :charset
def charset
if request.xhr?
@response.headers["Content-Type"] ||=
"text/javascript; charset=iso-8859-1"
else
@response.headers["Content-Type"] ||=
"text/html; charset=iso-8859-1"
end
end
end
28 Dezember 2006
Ruby on Rails and ä,ö,ü etc
Abonnieren
Kommentare zum Post (Atom)
1 Kommentare:
Great! That was exactly what I was looking for.
Kommentar veröffentlichen