Programming Forums
User Name Password Register
 

RSS Feed
FORUM INDEX | TODAY'S POSTS | UNANSWERED THREADS | ADVANCED SEARCH

Reply
 
Thread Tools Display Modes
Old Apr 8th, 2006, 11:03 PM   #1
Sane
Programming Guru
 
Sane's Avatar
 
Join Date: Apr 2005
Location: Waterloo, Ontario
Posts: 2,086
Rep Power: 6 Sane will become famous soon enough
Send a message via MSN to Sane
Closing <form> without a gap?

How do I close the <form> tag without creating a newline after the form was closed?

http://jammersbase.ath.cx/ <-- Look at the O2Jam Song Battle 2006 - Round #9 part.

You can see here how the form tag stretches the border of the surrounding region, due to the placement of </form>.

Any way around this?
Sane is offline   Reply With Quote
Old Apr 8th, 2006, 11:14 PM   #2
mongeau
Newbie
 
mongeau's Avatar
 
Join Date: Apr 2006
Location: Fargo, ND
Posts: 29
Rep Power: 0 mongeau is on a distinguished road
Send a message via MSN to mongeau
Quote:
Originally Posted by Sane
How do I close the <form> tag without creating a newline after the form was closed?

http://jammersbase.ath.cx/ <-- Look at the O2Jam Song Battle 2006 - Round #9 part.

You can see here how the form tag stretches the border of the surrounding region, due to the placement of </form>.

Any way around this?

Could you post a screeny of what you mean? I can't seem to figure out where, or what exactly you are talking about.
__________________
I wish I was you, so I could be friends with me.
mongeau is offline   Reply With Quote
Old Apr 8th, 2006, 11:44 PM   #3
titaniumdecoy
Expert Programmer
 
titaniumdecoy's Avatar
 
Join Date: Nov 2005
Posts: 930
Rep Power: 4 titaniumdecoy is on a distinguished road
Send a message via AIM to titaniumdecoy
Set the form's margin to 0.
titaniumdecoy is online now   Reply With Quote
Old Apr 9th, 2006, 10:20 AM   #4
Lich
Professional Programmer
 
Lich's Avatar
 
Join Date: May 2005
Location: Detroit
Posts: 254
Rep Power: 4 Lich is on a distinguished road
Send a message via AIM to Lich Send a message via MSN to Lich
Quote:
Originally Posted by titaniumdecoy
Set the form's margin to 0.
I didn't even know you could set a form margin. Assuming there's only 1 form on the page, I've just been making the bulk of the page part of the form. So could we do CSS with it then I assume?

[PHP]
form
{
margin: 0;
}[/PHP]
__________________
--John Cruz
Web Developer
www.cruzweb.net
Lich is offline   Reply With Quote
Old Apr 9th, 2006, 9:19 AM   #5
Sane
Programming Guru
 
Sane's Avatar
 
Join Date: Apr 2005
Location: Waterloo, Ontario
Posts: 2,086
Rep Power: 6 Sane will become famous soon enough
Send a message via MSN to Sane
Wee! Thank-you.
Sane is offline   Reply With Quote
Old Apr 9th, 2006, 9:35 AM   #6
DaWei
Resident Grouch
 
DaWei's Avatar
 
Join Date: Jun 2005
Posts: 6,453
Rep Power: 10 DaWei is on a distinguished road
Just a side note. The default values for many things are not zero. Sometimes they aren't even what one would expect (though that's, of couse, a matter of opinion). It can be a huge pain in the south end of a northbound designer.
__________________
Abstraction doesn't make it impossible to write bad code; it makes it possible to write superior code.
Contributor's Corner: Grumpy on C++ Exceptions DaWei on Pointers
DaWei is offline   Reply With Quote
Old Apr 9th, 2006, 12:13 PM   #7
DaWei
Resident Grouch
 
DaWei's Avatar
 
Join Date: Jun 2005
Posts: 6,453
Rep Power: 10 DaWei is on a distinguished road
Yup...
__________________
Abstraction doesn't make it impossible to write bad code; it makes it possible to write superior code.
Contributor's Corner: Grumpy on C++ Exceptions DaWei on Pointers
DaWei is offline   Reply With Quote
Old Apr 9th, 2006, 12:58 PM   #8
titaniumdecoy
Expert Programmer
 
titaniumdecoy's Avatar
 
Join Date: Nov 2005
Posts: 930
Rep Power: 4 titaniumdecoy is on a distinguished road
Send a message via AIM to titaniumdecoy
I've seen the following used to set the margin and padding of every element to 0:

* { margin: 0; padding: 0; }
Although I'm not sure how compatible this is with different browsers.
titaniumdecoy is online now   Reply With Quote
Old Apr 9th, 2006, 4:38 PM   #9
DaWei
Resident Grouch
 
DaWei's Avatar
 
Join Date: Jun 2005
Posts: 6,453
Rep Power: 10 DaWei is on a distinguished road
The non-zero defaults are there for a purpose, of couse, even if one disagrees with their exact values. Unilaterally defeating them with a simple statement seems like an idea that would cause the investment of much more effort in order to restore a halfway decent appearance. Just a thought. I have a bad habit of sitting behind the barn, watching the crops grow, and wondering about such things. Oh, well, time and effort are free.
__________________
Abstraction doesn't make it impossible to write bad code; it makes it possible to write superior code.
Contributor's Corner: Grumpy on C++ Exceptions DaWei on Pointers
DaWei is offline   Reply With Quote
Old Apr 9th, 2006, 7:21 PM   #10
Ooble
I eat cake for breakfast.
 
Ooble's Avatar
 
Join Date: Jul 2004
Location: In my box.
Posts: 4,434
Rep Power: 9 Ooble is on a distinguished road
I used to do that same thing, but many things, as DaWei said, have margins and padding for a reason. Paragraphs use margin-bottom to space themselves out, and lists use margin-left or padding-left (depending on your browser) to indent themselves.
__________________
Me :: You :: Them
Ooble is offline   Reply With Quote
Reply

Bookmarks

« Previous Thread in Forum | Next Thread in Forum »

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump




DaniWeb IT Discussion Community
All times are GMT -5. The time now is 1:19 AM.

Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC