Posted By

deschism on 07/10/09


Tagged

ajax rails layout


Versions (?)

Who likes this?

2 people have marked this snippet as a favorite

webstic
almazom


Remove Layouts from Ajax Requests


 / Published in: Rails
 

  1. def render(*args)
  2. args.first[:layout] = false if request.xhr? and args.first[:layout].nil?
  3. super
  4. end

Report this snippet  

Comments

RSS Icon Subscribe to comments
Posted By: deschism on July 10, 2009

Place in application controller

Posted By: almazom on October 14, 2009

intresting

You need to login to post a comment.