Displaying 1 result from an estimated 1 matches for "howcoolisit".
2011 Jan 06
2
Link_to parameters
Hello,
I would like to have a link_to automatically populate a field in the
form that it is linking to.
For example (excuse my silly words, im trying to make a point)
<%= link_to "Add a COOL Post", new_post_path, :howcoolisit => ''COOL''
%>
<%= link_to "Add a NOTCOOL Post", new_post_path, :howcoolisit =>
''NOTCOOL'' %>
Then, I would have a field in that form:
<%= f.hidden_field :howcoolisit %>
And I would want it to be populated automatically (either...