newgenmarketing — 2011-02-06T06:57:13-05:00 — #1
I am new to website development and i am learning HTML. when i was reading about it; i come to know this term EMpty element but it is not defined properly.
I wonder if you could explain that to me?
xhtmlcoder — 2011-02-06T07:36:18-05:00 — #2
Element types that are designed to have no content are called 'empty' elements.
scallioxtx — 2011-02-06T07:59:52-05:00 — #3
Examples include (but are not limited to) a line break, <br> and a horizontal rule, <hr>
victorinox — 2011-02-06T08:02:17-05:00 — #4
For refs, see the Elements section of the W3 spec for HTML 4.01 (Empty elements are marked by an E).
Differences in XHTML 1.0.
newgenmarketing — 2011-02-06T10:38:24-05:00 — #5
thanks a lot for your help
ralphm — 2011-02-06T17:29:33-05:00 — #6
I guess you could also add elements that are not technically 'empty' elements, but which have been left empty by the author, such as an empty
<p></p> element. But in this case it's not a class of element so much as the state of an element. (I just made that up, but it sounds cool. )
zcorpan — 2011-02-06T18:07:16-05:00 — #7
This is why HTML now calls <br> and friends for "void" elements.
ralphm — 2011-02-06T18:20:25-05:00 — #8
I also wondered where the term "replaced" elements fits in, for things like images. Is it technical term or not, as it wasn't included in Victorinox's link above?
zcorpan — 2011-02-06T18:39:36-05:00 — #9
Replaced elements is a CSS term, not an HTML term. See:
ralphm — 2011-02-06T18:49:28-05:00 — #10
Ah thanks. I should have looked it up first.
xhtmlcoder — 2011-02-07T05:31:41-05:00 — #11
The terms empty element and void were discussed a while back in this thread.
newgenmarketing — 2011-02-07T12:06:49-05:00 — #12
thanks once again for such a deep help. i would never have done that myself.. you do not know me