473,386 Members | 1,798 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

<form>...</form> - how to supress blank space after </form> in IE?


This is a minor thing and only appears in IE (so far), but I'd like to know to
correct it (if possible).

Whenever I use a form on a webpage, Explorer always leaves a blank line
following the </form> tag but Mozilla doesn't. Is there a way to supress the
blank line?

Thanks
Rob
www.rcp.ca

Dec 30 '05 #1
4 3688
rob c said the following on 12/30/2005 12:13 PM:
This is a minor thing and only appears in IE (so far), but I'd like to know to
correct it (if possible).

Whenever I use a form on a webpage, Explorer always leaves a blank line
following the </form> tag but Mozilla doesn't. Is there a way to supress the
blank line?


Remove the extra whitespace from your source code.

Irrelevant to JS though.

--
Randy
comp.lang.javascript FAQ - http://jibbering.com/faq & newsgroup weekly
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
Dec 30 '05 #2


rob c wrote:
Whenever I use a form on a webpage, Explorer always leaves a blank line
following the </form> tag but Mozilla doesn't. Is there a way to supress the
blank line?


form is a block element like div or p so what you see is probably the
normal layout for the block element.
CSS allows you to change that, see the display property for instance
<http://www.w3.org/TR/CSS21/visuren.html#display-prop>
With inline CSS you can do e.g.
<form style="display: inline;">
or you better use a stylesheet with e.g.
#someForm { display: inline; }
and then an id attribute
<form id="someForm">
on that form element.
Depending on what you want to change it might also be helpful or
necessary to change the margin e.g.
<form style="margin-bottom: 0;">
If you have further questions on that try a tutorial on CSS and then a
CSS newsgroup.

--

Martin Honnen
http://JavaScript.FAQTs.com/
Dec 30 '05 #3
"rob c" <gr***********@rcp.ca> wrote in message
news:N6******************************@tbaytel.net. ..

This is a minor thing and only appears in IE (so far), but I'd like to know to correct it (if possible).

Whenever I use a form on a webpage, Explorer always leaves a blank line
following the </form> tag but Mozilla doesn't. Is there a way to supress the blank line?

Thanks
Rob
www.rcp.ca


Try: <form style="margin:0px">
Dec 30 '05 #4
In message <43***********************@newsread4.arcor-online.net> - Martin
Honnen <ma*******@yahoo.de> writes:
:>
:>rob c wrote:
:>
:>> Whenever I use a form on a webpage, Explorer always leaves a blank line
:>> following the </form> tag but Mozilla doesn't. Is there a way to supress the
:>> blank line?
:>
:>form is a block element like div or p so what you see is probably the
:>normal layout for the block element.
:>CSS allows you to change that, see the display property for instance
:> <http://www.w3.org/TR/CSS21/visuren.html#display-prop>
:>With inline CSS you can do e.g.
:> <form style="display: inline;">
:>or you better use a stylesheet with e.g.
:> #someForm { display: inline; }
:>and then an id attribute
:> <form id="someForm">
:>on that form element.
:>Depending on what you want to change it might also be helpful or
:>necessary to change the margin e.g.
:> <form style="margin-bottom: 0;">
:>If you have further questions on that try a tutorial on CSS and then a
:>CSS newsgroup.
:>
:>--
:>
:> Martin Honnen
:> http://JavaScript.FAQTs.com/

As soon as you said "...form is a block element like div or p..." a small
light bulb started to flicker.

Thank you!
Rob
Dec 30 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Sims | last post by:
Hi, This will validate, (http://validator.w3.org/) <form method="POST" action="" name='xForm' style='background:inherit;'> <table style='background:inherit; width:100%;'> <tr width=80%> <td>...
5
by: Domestos | last post by:
Hi all - please help... using <FORM> HTML tag for user input and need to get get data from it and store in php variable... <input type="text" name="user_name" size="18" maxlength="16"...
6
by: Michael Hamm | last post by:
Hi, I'm trying to write a <form> whihc will retrieve a Web page on another server. I have (essentially) this: <form action="http://cgi.cs.indiana.edu/~oracle/digest.cgi"> <input...
2
by: Keiron Waites | last post by:
I have the following code: <input type="text" name="search" class="search_top"> <a href="" onclick="window.location='search.inc.php'+document..search. value; return false;"...
10
by: Phlip | last post by:
HTMListas: (Apologies for I can't Google for this - too many common words.) I have a <form> tag. It thinks I want a <p> break before and after the form. I don't. (My forms are sneaky and...
6
by: snacktime | last post by:
I've searched and searched and have not found a solution to suppress the margin on form or href tags so that there is no space before or after the tag. The only way I have found to do this is to...
3
by: Goran Djuranovic | last post by:
Hi all, How do I get rid of a break (an empty row) before <form> tag in ASP.NET? I set the "topmargin=0" inside the <body> tag. When I look at the page on a regular IE, the space is gone, but when...
2
by: Shawn H | last post by:
Hi guys, I'm experiencing this really strange issue with a HTML form, because no data gets posted. Basically, everything is written in ASP. Firstly, a user fills in an online (ASP) form, and...
4
by: Magnus Warker | last post by:
Hello group, I am producing a form within a table: <table> <tr> <td> <form> ... </form>
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.