Click here to get back home

HTML table position text injector?

 HomeNewsGroups | Search | About
 comp.infosystems.www.authoring.html    Post an article   get this group's latest topics as an RSS feed add this group's latest topics to your My MSN content add this group's latest topics to your My Yahoo content
Subject Author Date
HTML table position text injector? Dan Jacobson 03-17-2005
Get Chitika Premium
Posted by Dan Jacobson on March 17, 2005, 8:02 am
Please log in for more thread options


Gentlemen, often HTML tables meant for regular monitors become hard to
keep one's place reading when viewed on small handheld devices. So
let's insert visual clues -- letters or numbers indicating what column
we are looking at -- right into the text of the table, so the user is
sure to know what column an item was in, no matter how jumbled the
table ends up.

Let's put a,b,c,d before each bus departure time:
aNurdsburg bTurdsburg cNorflewitz dBlahsville
eSoftstools fBoogerworth gSnitsville
a16:20 b16:50 c17:15 d
e18:50 f19:20 g22:00
(Blahsville to boring to stop in these days.)

One might further deal with e.g., COLSPAN="3": a-c or abc.
Multi-dimensional tables: a3, c7b etc.

HTML::TableExtract, HTML::Parser is way over my head.
Anyway perhaps somebody has already made a table position text injector?

(What I did:)
$ wget -O - http://www.fybus.com.tw/bus8.htm| #[1.6MB Big5]
tr -d n|perl -pwe 's/<t[dhr]/n$&/ig'|
perl -pwe '$c=ord qif/<tr/i;
s/<t[dh][^>]*>(<[^t/][^>]*>|&nbsp;|s)*/$&.chr $c++/ige'
.... plucker-build ... pilot-xfer


Posted by me on March 17, 2005, 9:31 am
Please log in for more thread options


> Gentlemen, often HTML tables meant for regular monitors become hard to
> keep one's place reading when viewed on small handheld devices. So
> let's insert visual clues -- letters or numbers indicating what column
> we are looking at -- right into the text of the table, so the user is
> sure to know what column an item was in, no matter how jumbled the
> table ends up.
>
> Let's put a,b,c,d before each bus departure time:
> aNurdsburg bTurdsburg cNorflewitz dBlahsville
> eSoftstools fBoogerworth gSnitsville
> a16:20 b16:50 c17:15 d
> e18:50 f19:20 g22:00
> (Blahsville to boring to stop in these days.)
>
> One might further deal with e.g., COLSPAN="3": a-c or abc.
> Multi-dimensional tables: a3, c7b etc.
>
> HTML::TableExtract, HTML::Parser is way over my head.
> Anyway perhaps somebody has already made a table position text injector?
>
> (What I did:)
> $ wget -O - http://www.fybus.com.tw/bus8.htm| #[1.6MB Big5]
> tr -d n|perl -pwe 's/<t[dhr]/n$&/ig'|
> perl -pwe '$c=ord qif/<tr/i;
> s/<t[dh][^>]*>(<[^t/][^>]*>|&nbsp;|s)*/$&.chr $c++/ige'
> ... plucker-build ... pilot-xfer

Son, I hate to burst your bubble but I'm not waiting for a 1.6MB table to
download, most especially without a loading message to tell me if the page
even exists.
Signed,
me




Posted by Jukka K. Korpela on March 18, 2005, 7:47 am
Please log in for more thread options



> Gentlemen, often HTML tables meant for regular monitors become hard
> to keep one's place reading when viewed on small handheld devices.
> So let's insert visual clues -- letters or numbers indicating what
> column we are looking at -- right into the text of the table, so
> the user is sure to know what column an item was in, no matter how
> jumbled the table ends up.

In terms of HTML authoring for the WWW, which is the topic of one of
the groups you posted to, that's not feasible. You would add some stuff
that you expect to be useful in a (currently relatively small) number
of browsing situations, but you would surely mess things up in a
majority of browsing situations.

Browsers for small devices can be pretty good in working with the
limited space. I wouldn't try to do better with some page-specific or
site-specific tricky techniques that may well do things worse _also_ on
small devices.

There are several techniques in HTML to assist the identification of
table rows and columns in presenting a table, such as the scope, abbr,
headers, and axis attributes. They are not very widely known, and most
books don't describe them much, and browsers utilize them rather
little, but I would say that some of them are _still_ a better, more
constructive approach. And they are described in HTML specifications.
Minimally, I would say, you could use scope and abbr, which are fairly
to understand and use.

I think you should first decide what to aim at, then consider the
programming techniques needed to achieve that. Hence followups trimmed.
(Surely there's the possibility that technical limitations exclude some
goals or otherwise affect the primary decision. But we have so far no
evidence of that in this case - surely you can do anything in Perl.:-)

--
Yucca, http://www.cs.tut.fi/~jkorpela/
Pages about Web authoring: http://www.cs.tut.fi/~jkorpela/www.html



Similar ThreadsPosted
Trying to position table columns December 28, 2005, 9:43 am
Table position not working on Mozilla? August 17, 2004, 9:32 pm
I thought it was "impossible" to precisely dictate image position with html commands? October 3, 2004, 10:41 am
Mozila Firefox: iframe keep relocate its position when set display block/hiden of another html component? October 11, 2004, 3:57 pm
Text and Image inside table Alight Text Left and Image right in same cell ?? October 24, 2006, 12:55 am
Text slops into table in MSIE July 31, 2004, 6:47 pm
How can I force clipping of text in a table cell? October 18, 2004, 8:49 am
Truncating text in a table rather than wrapping to a new line? March 21, 2007, 5:07 pm
table issue, centered column not possible, when text in other columns September 1, 2007, 3:34 pm
remembering div position September 19, 2006, 8:50 am

Our other projects:

Art Dolls, Fairies and Mermaids - Sunnyfaces.net

Roy's Linux, Programming and Search Engines messages

1-Script XML SitemapXML Sitemap