Forum Moderators: not2easy

Message Too Old, No Replies

Lining up buttons and links within multiple forms

lining up forms and links

         

salewit

7:12 pm on Sep 15, 2009 (gmt 0)

10+ Year Member



Very simplified example:


<form action="option1.php">
<input type="image" src="button_option_1.gif">
</form>

<a href="option2.php"><img src="button_option_2.gif"></a>

<form action="option3.php">
<input type="image" src="button_option_3.gif">
</form>

Can I have these three buttons line up horizontally, and if so, how? I tried putting a <DIV style="display:inline;">around the whole thing, but it did nothing.

Thanks.

londrum

7:20 pm on Sep 15, 2009 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



you could just put the image inside the form, and make it so both the input and image are
display:inline

<form action="option1.php">

<input type="image" src="button_option_1.gif">

<a href="option2.php"><img src="button_option_2.gif"></a>

</form>

i would put the second input button inside the first form, and scrap the second form. you can test for each button in the same php script. you probably don't need two scripts.

salewit

7:32 pm on Sep 15, 2009 (gmt 0)

10+ Year Member



Thanks for the quick reply. This is a checkout script, and what I'm doing is giving people checkout options:

1) Continue to OUR secure checkout (our link)
2) Google Checkout (their own submit button)
3) PayPal Checkout (their own submit button)

Obviously I'm forced to use their submit buttons with 2 forms.

londrum

7:59 pm on Sep 15, 2009 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



just make everything display:inline, or do float:left on them.

if you do it for the form, input and image tags then that should be it.