Avoiding 'banding' when defining FORM area

JavaScript and client side scripting.

Moderator: General Moderators

Post Reply
mjseaden
Forum Contributor
Posts: 458
Joined: Wed Mar 17, 2004 5:49 am

Avoiding 'banding' when defining FORM area

Post by mjseaden »

Hi,

Often, when I define a form, something like this:

Code: Select all

<HTML>
<BODY>
<TABLE>
// stuff
<FORM>
// more stuff, including perhaps several more tables inside tables
</FORM>
</TABLE>
</BODY>
</HTML>
I get mysterious 'bands' occurring both immediately above and below the scope of the form, often 15 pixels in height or similar.

Can anyone tell me how I can avoid this irritating phenomena?

Many thanks

Mark
User avatar
patrikG
DevNet Master
Posts: 4235
Joined: Thu Aug 15, 2002 5:53 am
Location: Sussex, UK

Post by patrikG »

moved to client-side
User avatar
andre_c
Forum Contributor
Posts: 412
Joined: Sun Feb 29, 2004 6:49 pm
Location: Salt Lake City, Utah

Post by andre_c »

set the css property margin on the form tag to 0px:

Code: Select all

<style>
form &#123; margin: 0px; &#125;
</style>
User avatar
no_memories
Forum Contributor
Posts: 145
Joined: Sun Feb 01, 2004 7:12 pm
Location: New York City

Post by no_memories »

Andre_c:

for I.E. you need to adjust this to:

table form {
margin: 0xp 0xp 1px 0px;
padding: 0px;
}

The 1px at the bottom is so I.E. can tell there is a margin at all.

margin = top right bottom left
Post Reply