2008年1月16日星期三

不用render模板时,不使用布局的方法

# Renders the template for the action "short_goal" within the current controller,
# but without the current active layout
render :action => "short_goal", :layout => false

# Renders the template for the action "long_goal" within the current controller,
# but with a custom layout
render :action => "long_goal", :layout => "spectacular"


Rails API文档上的。

没有评论: