RailsCasts Pro episodes are now free!
Learn more or hide this
GitHub User: tguevin
The previous code works for new models, but you can get the existing id like this:
<li id="entry_<%= f.object.id || f.object_name.gsub(/[^0-9]+/,'') %>">
Coda, I found this link: http://railsforum.com/viewtopic.php?id=40499
so your >> here? <<
could be something like
class => "net_device_<%= f.object_name.gsub(/[^0-9]+/,'') %>"
not sure about the content tag and how you specify the class/id for CSS.
I'm using a fieldset as follows:
<fieldset id="entry_<%= f.object_name.gsub(/[^0-9]+/,'') %>">
Good luck :)
The previous code works for new models, but you can get the existing id like this:
Coda, I found this link:
http://railsforum.com/viewtopic.php?id=40499
so your >> here? <<
could be something like
not sure about the content tag and how you specify the class/id for CSS.
I'm using a fieldset as follows:
Good luck :)