Click to See Complete Forum and Search --> : FORM tag border on Windows IE ???


antonielloj
05-06-2003, 04:55 PM
hey all. ive got a simple form that has been placed inside a pretty complex page layout. for some reason, it seems as though the <form> tag is creating an undesired border around the form when i look at it on windows version of IE (all other platforms and browsers render ok). this 'padding' is pushing down all other table elements and compeltely throwing off the layout of the page.

i know that the problem is explicitly related to the <form> tag, because when i comment out the <form> and </form> tags, the page renders correctly.

here is the code for my form, incase it helps. i've set border=0 on all input objects, still to no avail. is there any way to circumvent this problem via CSS or some other attirbute that im simply not aware of? any help would be greatly appreciated. cheers!

---

<form action="blahblahblah.asp" method="post" name="search" target="_blank" language="JavaScript" onsubmit="return ValidateZip()">
<tr>
<td><IMG src="images/vt/findcomicshopsh.gif" WIDTH=110 HEIGHT=12 ALT="" border=0></td>
</tr><tr>
<td>
<TABLE WIDTH=143 BORDER=0 CELLPADDING=0 CELLSPACING=0 class="font">
<tr>
<td><IMG src="images/vt/spacer.gif" WIDTH=14 HEIGHT=1 ALT="" border=0></td>
<td><INPUT TYPE="text" name="Zip" SIZE="10" VALUE="enter zip" border=0></td>
<td><input name="image" type="image" src="/dccomics/3_0/images/vt/gob.gif" ALT="GO" WIDTH=24 HEIGHT=9 BORDER=0></td>
</tr>
</table>
</td>
</tr>
</form>

khalidali63
05-06-2003, 05:19 PM
there are errors like form element does not have a language attribute and so,but I can't see any border around the form...are your its form..

pyro
05-06-2003, 05:22 PM
Just a shot in the dark, but is this what you need?

<form action="blahblahblah.asp" method="post" name="search" target="_blank" language="JavaScript" onsubmit="return ValidateZip()" style="padding:0px; spacing:0px;">

khalidali63
05-06-2003, 05:26 PM
excellent solution pyro,however question still remains, why a form is creating a border to begin with,my guess is there is more code that has some imact on the rendering of the page not just the one is posted above..

antonielloj
05-06-2003, 06:21 PM
well, im pretty sure that its explicitly related to the form tag, simply because when i comment out the <form> and </form> tags (but dont touch any of the elements sandwiched between them), the layout is perfect.

would it help if i posted a link to a mock-up html page that contains this problem?

let me know. and thanks for all of your help.

cheers
j

khalidali63
05-06-2003, 07:03 PM
yep sure...post a link,it always helps

pyro
05-06-2003, 10:59 PM
I believe the form tag, as a default, adds spacing around the form. I tested in IE and NN, and in IE, it adds to the top and bottom, and in NN, only on the bottom. Did you try the solution I posted above?

khalidali63
05-06-2003, 11:23 PM
Interesting...this seem to have done the trick.

<form name="form1" action="" onsubmit="" style="margin-top:0px;margin-bottom:0px;" >

margin property takes care of that,I tested it in NS6+ and IE6+