Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge pull request #8737 from tricknotes/info-page-style

Fix info page style [ci skip]
  • Loading branch information...
commit 1e1c7afe3fed844e1a11a75e125a0ac7af1d468b 2 parents a8637c8 + eb34327
@carlosantoniodasilva carlosantoniodasilva authored
View
2  railties/lib/rails/info_controller.rb
@@ -3,7 +3,7 @@
class Rails::InfoController < ActionController::Base # :nodoc:
self.view_paths = File.expand_path('../templates', __FILE__)
prepend_view_path ActionDispatch::DebugExceptions::RESCUES_TEMPLATE_PATH
- layout 'application'
+ layout -> { request.xhr? ? nil : 'application' }
before_filter :require_local!
View
5 railties/lib/rails/templates/rails/welcome/index.html.erb
@@ -174,8 +174,9 @@
<script>
function about() {
var info = document.getElementById('about-content'),
- xhr = new XMLHttpRequest();
- xhr.open("GET","rails/info/properties",false);
+ xhr = new XMLHttpRequest();
+ xhr.open("GET", "rails/info/properties", false);
+ xhr.setRequestHeader("X-Requested-With", "XMLHttpRequest");
xhr.send("");
info.innerHTML = xhr.responseText;
info.style.display = 'block'
Please sign in to comment.
Something went wrong with that request. Please try again.