Defining the Content-Language header in Rails -



Defining the Content-Language header in Rails -

according w3c, viable , preferred way communicate language of intended audience providinga content-language header. relevant part:

metadata language of intended audience best declared outside document in http content-language header.

how can send such header rails?

it'd preferred utilize i18n framework this:

response.headers["content-language"] = i18n.locale.to_s

read more here: http://guides.rubyonrails.org/i18n.html

ruby-on-rails-4

Comments

Popular posts from this blog

formatting - SAS SQL Datepart function returning odd values -

c++ - Apple Mach-O Linker Error(Duplicate Symbols For Architecture armv7) -

php - Yii 2: Unable to find a class into the extension 'yii2-admin' -