Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > HTML > Table rows and paragraphs

Reply
Thread Tools

Table rows and paragraphs

 
 
Samuel van Laere
Guest
Posts: n/a
 
      06-10-2010
I do not use tables very often so I wonder about this:

<tr>
<td><p>Achromaat</p></td>
<td><p>De persoon mist het kleuren zien ten gevolge van het ontbreken
van alle kegeltjes.</p></td>
</tr>

Are the paragraphs okay or are they not needed?
Is there a reason to use/not use paragraphs within a <td>?

My table is to found here, just in case one needs to see the bigger picture:
http://oukjeweb.com/tabel.html

cheers,
Samuel van Laere


 
Reply With Quote
 
 
 
 
Beauregard T. Shagnasty
Guest
Posts: n/a
 
      06-10-2010
Samuel van Laere wrote:

> I do not use tables very often so I wonder about this:
>
> <tr>
> <td><p>Achromaat</p></td>
> <td><p>De persoon mist het kleuren zien ten gevolge van het ontbreken
> van alle kegeltjes.</p></td>
> </tr>
>
> Are the paragraphs okay or are they not needed?
> Is there a reason to use/not use paragraphs within a <td>?


I would say they are superfluous in your <td>s. They do, however, lead
to semantic markup as you are actually including paragraphs of text in
the table.

> My table is to found here, just in case one needs to see the bigger
> picture: http://oukjeweb.com/tabel.html


The validator does not object to your paragraphs. However, it did note
that there is a missing closing brace for the style: #overzicht ol {

--
-bts
-Four wheels carry the body; two wheels move the soul
 
Reply With Quote
 
 
 
 
Samuel van Laere
Guest
Posts: n/a
 
      06-10-2010
"Beauregard T. Shagnasty" <(E-Mail Removed)> schreef in bericht
news:huri2v$qul$(E-Mail Removed)-september.org...
>
> I would say they are superfluous in your <td>s. They do, however, lead
> to semantic markup as you are actually including paragraphs of text in
> the table.
>


So in my case the use of paragraphs makes sence then.
Seems fine to me too.

>> My table is to found here, just in case one needs to see the bigger
>> picture: http://oukjeweb.com/tabel.html

>
> The validator does not object to your paragraphs. However, it did note
> that there is a missing closing brace for the style: #overzicht ol {
>


True the validator is happy with or without paragraphs.
Thanks for spotting the missing closing brace, its fixed now.

cheers,
Samuel van Laere


 
Reply With Quote
 
Jukka K. Korpela
Guest
Posts: n/a
 
      06-10-2010
Samuel van Laere wrote:

> <tr>
> <td><p>Achromaat</p></td>
> <td><p>De persoon mist het kleuren zien ten gevolge van het
> ontbreken van alle kegeltjes.</p></td>
> </tr>
>
> Are the paragraphs okay or are they not needed?


A single word hardly constitutes a paragraph. A paragraph is "a subdivision
of a written composition that consists of one or more sentences, deals with
one point or gives the words of one speaker, and begins on a new usually
indented line", to quote
http://www.merriam-webster.com/dictionary/paragraph

It might be argued that the defining text in the second cell is a paragraph,
but it's really just part of a sentence, implying the word being defined as
the subject and some predicate expression like "is" or "is defined as". I
think this even applies to those cases in your table where the second-column
cell contains complete sentences. They still don't constitute a _paragraph_,
i.e. a relatively self-contained passage of text - at least the term being
defined needs to be implied here.

Of course this is mostly just theoretical, since correct semantics of markup
has little impact on the practical properties of an HTML document. Still,
why should we use wrong markup when we can easily, and often easier, use
more proper markup?

> Is there a reason to use/not use paragraphs within a <td>?


It's hard to see how it could do any good.

The default top and bottom margins of <p> elements might cause some
undesirable formatting. Oddly, you seem to have set them to zero, except for
top margin, causing some waste of space. Just omitting <p> markup is the
best approach. If you really want the extra spacing you have now, you can
easily create it using padding-top for <td>.

> My table is to found here, just in case one needs to see the bigger
> picture: http://oukjeweb.com/tabel.html


I have to contradict myself a bit. Sometimes in tables of definitions like
this*), the defining expression is so long and complicated that it should
maybe be divided into two or more paragraphs. For example, your definition
for "gezichtsscherpte" is fairly long and would probably benefit from a
division into paragraphs. But then a <td> would contain two or more <p>
elements whereas other cells in the same column would have just text
content.

I'd respond by asking "So what?" When you define terms, sometimes the
defining expression can be a single word (like a more common synonym),
sometimes a few words, or an almost complete sentence, or even more - maybe
several paragraphs. It could also be a list, or contain a list, or maybe an
image. There is no reason why such variation, when it exists (it might be
inferior presentation style, but that's debatable, and not really relevant
here), should not be reflected in the markup. If the cells contain really
different types of stuff, they can well contain different markup elements.

*) A table is good markup. Theoretically you could additionally use <dfn>
markup for the term being defined or alternatively use <dl> for the whole
stuff, but don't bother - such markup approaches have drawbacks and they
hardly achieve anything, in this world where web browsers and robots are
mostly semantically ignorant, despite all the idle babbling about "semantic
web". There is no really adequate markup for definitions, still less sets of
definitions, in HTML, and using a two-column table is quite OK.

--
Yucca, http://www.cs.tut.fi/~jkorpela/

 
Reply With Quote
 
Samuel van Laere
Guest
Posts: n/a
 
      06-10-2010
"Jukka K. Korpela" <(E-Mail Removed)> schreef in bericht
news:u7cQn.18122$(E-Mail Removed)...
> Samuel van Laere wrote:
>
>> <tr>
>> <td><p>Achromaat</p></td>
>> <td><p>De persoon mist het kleuren zien ten gevolge van het
>> ontbreken van alle kegeltjes.</p></td>
>> </tr>
>>
>> Are the paragraphs okay or are they not needed?

>
> A single word hardly constitutes a paragraph. A paragraph is "a
> subdivision of a written composition that consists of one or more
> sentences, deals with one point or gives the words of one speaker, and
> begins on a new usually indented line", to quote
> http://www.merriam-webster.com/dictionary/paragraph
>


--Snip lots of usefull text --

I'd exspected a reply of you Jukka, and its a extended one too, though thats
not very unusual with you.
You should make it a page on your website for others to learn from, or did I
just miss it?
While I might not agree with everyting you wrote, its still educational and
at the least its entertaining.
I'll remove those unneeded paragraphs, besides it also reduces the
filesize..

cheers,
Samuel (follower of Yucca)



 
Reply With Quote
 
Jenn
Guest
Posts: n/a
 
      06-12-2010
Ed Mullen wrote:
> Beauregard T. Shagnasty wrote:



>> The validator does not object to your paragraphs. However, it did
>> note that there is a missing closing brace for the style: #overzicht ol {

>
> That was REALLY a nice reply!
>
> I would have said something on the order of:
>
> "Ok! Go study! Learn!" And lots of other "stuff."
>
> Then come back and annoy us with silly questions you should have
> already figured out on you own.
>
> Geez. BSG! What happened to your slapping novices around?!!! Dang!


some people are simply more intelligent so they don't need to slap anyone
around....

--
Jenn (from Oklahoma)


 
Reply With Quote
 
 
 
Reply

Thread Tools

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
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
how to remove the punctuation and no need words from paragraphs kylin Python 1 11-04-2009 07:42 AM
Trouble Counting Words, Sentences and Paragraphs Max Norman Ruby 6 07-22-2009 04:54 PM
script for moving rows up and down and traverse thru rows of HTML table Subba Rao via DotNetMonster.com ASP .Net 0 03-19-2005 06:46 AM
Table/table rows/table data tag question? Rio HTML 4 11-05-2004 08:11 AM
"left floated" paragraphs and images using CSS? jersie0 HTML 0 11-23-2003 02:43 AM



Advertisments