Displaying 8 results from an estimated 8 matches for "overwrite_param".
Did you mean:
overwrite_params
2005 Sep 06
4
url_for: :overwrite_params went missing
Somewhere between 0.13.1 and the current SVN version
the :overwrite_params option to url_for (and related methods) went
missing. I can''t tell whether this was deliberate or by mistake, and I
have no idea how to get the same functionality in some other way
either.
Michael
--
Michael Schuerig Life is what happens
mailto:micha...
2006 Nov 21
1
fix for modularized controller using overwrite_params
Hey guys,
I realized some people have had problems with nested controllers and the
:overwrite_params call. The way I fixed it is like this:
:overwrite_params=>{:controller=>"/#{params[:controller]}"}
I would love to see if other people could improve on this, its not the
prettiest thing.
--
Posted via http://www.ruby-forum.com/.
--~--~---------~--~----~------------~-------~...
2005 Mar 03
0
where is :overwrite_params ?
HI,
it seems the :overwrite_params option has disappeared from the
url_builder. Is there a reason or is it just a side effect of the new
routes? Any chances to see it coming back?
If that matters, I use it a lot :-)
Raph
PS:
For those who don''t know it, it lets you use the current @params as
parameters for eg link_to, j...
2007 Apr 09
8
How do I use link_to with all the current options?
In one of my pages I want to create some URLs that go to the same
page, but tack on an extra parameter (column sorting stuff). How do I
do that?
I''ve tried
link_to "Title", :sort => "title"
and that''s pretty close...it keeps the controller name, but it doesn''t
include one of the parameters. I''m using nested routes, so the URL
should
2005 Nov 19
1
link_to weirdness
Hi,
I''ve got a page running at say http://example.com:3000/admin/players
Then I''ve this bit of code to generate a URL like:
http://example.com:3000/admin/players?order_col=fname&order_dir=desc
<%=link_to col[:label], :overwrite_params => {
:order_col => col[:field],
:order_dir => @order_dir == ''asc'' ? ''desc'' : ''asc'' }%>
But instead it renders:
http://example.com:3000/admin/admin/players?order_col=fname&order_dir=desc
It''s doing ''admin'...
2006 Apr 18
6
Best Practice for Returning to Calling Page?
I have a partial, it''s a shopping cart display, it''s designed to appear
on several different pages of my site.
One of the buttons on the shopping cart empties the cart, and then I
want the calling page to redisplay.
In other words, the cart controller needs to return the visitor to the
same page -- however since the cart could appear on any given page, this
has to be
2006 Apr 25
6
Does Rails need more useful URL helpers?
....rhtml as well as to my helpers
that generate paging, sorting and limiting links. As I add more
parameters, the link_to commands in these files grow more and more
unreadable and the number of places I have to explicitly specify every
parameter in the query string increases.
I attempted to use :overwrite_params, but then all of a sudden link_to
does not seem to recognize my routes. It starts dumping URL-defined
params into the query string.
When I read about link_to, the description said that it intuitively
understood the hierarchy of parameters. If the :action changed, the :id
was nulled. If the :c...
2004 Oct 25
1
Rails 0.8: Just shy of 100 additions, changes, tweaks, and fixes!
...So
layout "weblog/standard" will use
weblog/standard (as always), but layout "standard" will use
layouts/standard.
* Fixed that partials (or any template starting with an underscore) was
publically viewable [Marten]
* Added HTML escaping to text_area helper.
* Added :overwrite_params to url_for and friends to keep the parameters
as they were passed to the current action and only overwrite a subset.
The regular :params will clear the slate so you need to manually add in
existing parameters if you want to reuse them. [raphinou]
* Fixed scaffolding problem with composite n...