By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
437,648 Members | 1,198 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 437,648 IT Pros & Developers. It's quick & easy.

Markup for dictionary/glossary

P: n/a
I'm looking for an appropriate markup for a dictionary/glossary.
A dummy example is

English German
eight acht
five fünf
four vier
nine neun
one eins
seven sieben
six sechs
three drei
two zwei
zero null

The first idea is of course a <TABLE>. Are there other possibilities?
For example, a definition list <DLcomes into my mind. Although
the German term does not really /define/ the English term,
<DLmight come closest to the concept of a dictionary/glossary.
Feb 7 '07 #1
Share this Question
Share on Google+
7 Replies


P: n/a
Wed, 7 Feb 2007 15:18:31 +0100: Andreas Prilop
<An***************@trashmail.net>: in sci.lang:
>I'm looking for an appropriate markup for a dictionary/glossary.
A dummy example is

English German
eight acht
five fünf
four vier
nine neun
one eins
seven sieben
six sechs
three drei
two zwei
zero null

The first idea is of course a <TABLE>. Are there other possibilities?
For example, a definition list <DLcomes into my mind. Although
the German term does not really /define/ the English term,
<DLmight come closest to the concept of a dictionary/glossary.
I used tables in my http://rudhar.com/lingtics/ptesdiff.htm, and it
suits me fine.
--
Ruud Harmsen - http://rudhar.com

Feb 7 '07 #2

P: n/a
Andreas Prilop wrote:
I'm looking for an appropriate markup for a dictionary/glossary.
A dummy example is
English German
eight acht
[...]
The first idea is of course a <TABLE>.
A table is IMHO a little bit harder to read, if a term has more than one
translation.
Are there other possibilities?
For example, a definition list <DLcomes into my mind. Although
the German term does not really /define/ the English term,
<DLmight come closest to the concept of a dictionary/glossary.
<DLis the most appropriate. 'definition' is the usual term for the
right part of a dictionary or glossary. The left part is called
'subject', 'keyword', 'term'.

On dict.cc you can see both variants and switch between <DLand <TABLE>:
http://www.dict.cc/englisch-deutsch/ink.html # DL
http://www.dict.cc/?s=ink # TABLE

wiktionary uses <DL>, and my nomen.at uses DL-style (but not DL itself).

But look into TEI. AFAIR they have some XSLT for conversion of
TEI-dict.XML to HTML.

Helmut Wollmersdorfer
Feb 7 '07 #3

P: n/a
On 7 Feb, 14:18, Andreas Prilop <AndreasPrilop2...@trashmail.net>
wrote:
I'm looking for an appropriate markup for a dictionary/glossary.
I'd go with <dl>, unless you had a strong argument for more than two
columns when I'd switch to <table>

Feb 7 '07 #4

P: n/a
Scripsit Helmut Wollmersdorfer:
A table is IMHO a little bit harder to read, if a term has more than
one translation.
Why? You can put the translations each on a line of its own inside a cell,
or you can have a row in the table for each pair of words so that for a word
with multiple translations, you use rowspan="..." in the first cell.

In practice, the desired visual appearance is important, since you cannot
turn a <dlinto tabular presentation or a table into non-tabular
presentation in CSS. (Tools might exist in principle but aren't supported by
the most common browser.)
<DLis the most appropriate. 'definition' is the usual term for the
right part of a dictionary or glossary. The left part is called
'subject', 'keyword', 'term'.
<dlis possible, since a translation can indeed be seen as a definition,
but it is debatable whether <tableis more logical.

There's a particular practical benefit in using a table. You (i.e., the
generic user) can copy the table into his favorite spreadsheet program
(i.e., MS Excel), which can interpret the table in a way that lets him
reorder it conveniently and e.g. produce a reverse glossary.
But look into TEI. AFAIR they have some XSLT for conversion of
TEI-dict.XML to HTML.
For a complicated dictionary, one might need to look at general structured
formats indeed, but for delivery in HTML format, much of the structure needs
to be lost anyway.

--
Jukka K. Korpela ("Yucca")
http://www.cs.tut.fi/~jkorpela/

Feb 7 '07 #5

P: n/a
Andreas Prilop wrote:
I'm looking for an appropriate markup for a dictionary/glossary.
A dummy example is

English German
eight acht
five fünf
four vier
nine neun
one eins
seven sieben
six sechs
three drei
two zwei
zero null

The first idea is of course a <TABLE>. Are there other possibilities?
For example, a definition list <DLcomes into my mind. Although
the German term does not really /define/ the English term,
<DLmight come closest to the concept of a dictionary/glossary.
Where I have a brief term with a longer definition, I use a definition
list. See my <http://www.rossde.com/internet/intr_gloss.htmlfor an
example.

Where I compare sets of two terms each that are about the same size
(including definitions), I use a table with a row per set of terms, with
two columns. This even works where occasionally a term on one side has
two or more terms on the other side. See my
<http://www.rossde.com/malaprops/malaprops.htmlfor an example.

Finally, where I know I will likely compare three or more terms in a
set, each with its own definition, I rely on CSS to format the page.
See my <http://www.rossde.com/malaprops/homonyms.htmlfor an example.
This example also uses sidebars to expand on how the terms in a set
differ. While the two-term page could have also been done this way, the
reverse is not true; this page could not reasonably be done with a table.

--

David E. Ross
<http://www.rossde.com/>

I use SeaMonkey as my Web browser because I want
a browser that complies with Web standards. See
<http://www.mozilla.org/projects/seamonkey/>.
Feb 7 '07 #6

P: n/a
Andreas Prilop <An***************@trashmail.netwrote in message
news:Pi******************************@s5b004.rrzn. uni-hannover.de...
I'm looking for an appropriate markup for a dictionary/glossary.
A dummy example is

English German
eight acht
five fünf
four vier
nine neun
one eins
seven sieben
six sechs
three drei
two zwei
zero null

The first idea is of course a <TABLE>. Are there other possibilities?
For example, a definition list <DLcomes into my mind. Although
the German term does not really /define/ the English term,
<DLmight come closest to the concept of a dictionary/glossary.
Have you looked at <OLOrdered Lists?
They often allow fast lookups with non-sequential binary searches.

Are you talking HTML, XML, SOAP or what?

pjk
Feb 8 '07 #7

P: n/a
On Thu, 8 Feb 2007, Paul J Kriha wrote:
Have you looked at <OLOrdered Lists?
They often allow fast lookups with non-sequential binary searches.
This is not a concern for a small list of words. I don't mean
heavy books like Webster's Dictionary.
Are you talking HTML, XML, SOAP or what?
HTML.
Feb 8 '07 #8

This discussion thread is closed

Replies have been disabled for this discussion.