Heavy Sixer
2008-Apr-05 02:45 UTC
[Facebooker-talk] url_for + :canvas => false weirdness for non resource controllers
I noticed something strange in my app today. It appears that the extra canvas path appended in url_for is back but only for controllers that are not resources. Here is an example I have in my site: campaigns is a resource checkout is not # With the canvas false flag (rdb:1) @controller.url_for(:controller => ''campaigns'', :action => ''show'', :id => 1,:canvas => false,:only_path => true) "/campaigns/1" (rdb:1) @controller.url_for(:controller => ''checkout'', :action => ''ipn'',:canvas => false,:only_path => true) "/pledgie/checkout/ipn" # With the canvas true flag (rdb:1) @controller.url_for(:controller => ''campaigns'', :action => ''ipn'',:canvas => true,:only_path => true) "/pledgie/campaign/1" (rdb:1) @controller.url_for(:controller => ''checkout'', :action => ''ipn'',:canvas => true,:only_path => true) "/pledgie/pledgie/checkout/ipn" Notice that the non resource controller "checkout" has an extra canvas path applied to it. Anyone know a way around this? Mark