john95127
(john95127)
1
I have in my application.rhtml a series of links that can help
navigate the application.
When I link_to I get the links on one horizontal line.
When I button_to I get a carriage return after each button.
link_to: <jobs> <inventories> <species>
button_to:
<jobs>
<inventories>
<species>
is there a way to control this behavior or a work around?
Thanks!
fxn
(Xavier Noria)
2
That helper creates a FORM with a DIV inside, which are block-level elements. You may control that a bit with CSS, with something like this:
<div id="buttons">
<jobs>
...
</div>
and then something like this:
#buttons form, #buttons div { display: inline }
This is all untested, but you see how it goes.
-- fxn
john95127
(john95127)
3
Can you show me how? I'm really new...
fxn
(Xavier Noria)
4
Once you got the buttons wrapped in the DIV throw
#buttons form, #buttons div {
display: inline
}
into stylesheets/application.css for instance, and load the stylesheet in the layout:
<%= stylesheet_link_tag "application.css" %>
Once said that, take into account that to let the user navigate to other pages you normally use links.
-- fxn