如果您使用的是 IE8,Rails 3 会自动添加 header 吗?我看到 X-UA-Compatible 的元标记设置为“IE=8.0000”,这打乱了我的一个观点。
我似乎找不到其他任何东西可以做到这一点,所以我想我应该问问这里的大脑。
谢谢, 规则
最佳答案
如果我们查看加载在 vanilla rails3 应用程序中的所有中间件:
rake middleware
(in /private/tmp/bla)
use ActionDispatch::Static
use Rack::Lock
use ActiveSupport::Cache::Strategy::LocalCache
use Rack::Runtime
use Rails::Rack::Logger
use ActionDispatch::ShowExceptions
use ActionDispatch::RemoteIp
use Rack::Sendfile
use ActionDispatch::Callbacks
use ActiveRecord::ConnectionAdapters::ConnectionManagement
use ActiveRecord::QueryCache
use ActionDispatch::Cookies
use ActionDispatch::Session::CookieStore
use ActionDispatch::Flash
use ActionDispatch::ParamsParser
use Rack::MethodOverride
use ActionDispatch::Head
use ActionDispatch::BestStandardsSupport
run Bla::Application.routes
ActionDispatch::BestStandardsSupport source正在设置 X-UA-Compatible header ,而不是 IE=8.000。你运行 3.0.0 吗?
关于javascript - Rails 3 自动添加 X-UA-Compatible header ?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/3807605/