tags:

views:

44

answers:

2

I have a jQuery dialog box with three buttons.

It looks like: Would you like to proceed to the signup page?

          < More Info > < OK > < Cancel >

Is there any way to put a line break between buttons so that I end up with: Would you like to proceed to the signup page?

                        < OK > < Cancel >
                            < More Info >
+2  A: 

Use the dialogClass option to add a custom class to the dialog and then write some CSS to style the s in a way that makes them appear one per line. The best method I've found is setting float: none and clear: both.

CalebD
Can I add CSS to a particular button? I only want a line break after cancel. Not after OK.
Brian
+1  A: 

Like this:

$('#dialog .ui-dialog-buttonpane button:last').css('clear', 'both');

You'll also need to make the button last, not first.

SLaks
Where do I put this code?
Brian
After calling `.dialog()`. See my sample: http://jsbin.com/idila/edit#javascript
SLaks