Jump to content

Problem with <form><td></td></form>


KiwiDave

Recommended Posts

Hi,

Got this little issue. It is to do with an image button and how it is displayed on screen

 

Now I have a button in a table field. I have code like this:

 

echo "<FORM ACTION = 'options.php' METHOD = 'GET'><TD align = 'center'>";

echo "<INPUT type = 'hidden' name='opt' value = '2'>";

echo "<INPUT type = 'hidden' name='user' value = '$user'>";

echo "<INPUT type = 'image' src='$deleteimg' value='Submit'></TD></FORM>”;

 

This works sweet in Internet Explorer and the formatting is great but Firefox and Safari do not like it and won’t show the image. Explorer and Firefox examples are shown below:

 

However I do this (moving the form inside the TD)

 

echo "<TD align = 'center'><FORM ACTION = 'options.php' METHOD = 'GET'>";

echo "<INPUT type = 'hidden' name='opt' value = '2'>";

echo "<INPUT type = 'hidden' name='user' value = '$user'>";

echo "<INPUT type = 'image' src='$deleteimg' value='Submit'></FORM></TD>”;

 

It works in Explorer, Firefox and Safari but the formatting comes out screwed up. Its appears to add a line to the bottom of the image making the single row now twice the size in space. It is almost as if it was creating a blank label at the bottom of the image.

 

Does anyone know why this is happening and what workaround there is so I can have the formatting of the first example and also have it compatible with Firefox and Safari.

 

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.