PDA

View Full Version : theherald columns read



krembo
01-15-2006, 01:37 PM
Hi, please check the way articles are shown in the herald website.
It has pagin and columns for reading articles. Anyone familiar with some free javascript code to do this? this could be very popular!

http://www.theherald.co.uk/news/53977.html

Twey
01-15-2006, 02:49 PM
Why use Javascript for layout? That's a simple CSS stylesheet. There are plenty of examples of the same available on the web.

krembo
01-15-2006, 02:52 PM
Can you please give a link for such an example.

Twey
01-15-2006, 03:16 PM
http://glish.com/css/2.asp
Needs a little tweaking for your purposes, but should do fine.

krembo
01-15-2006, 08:32 PM
I'm afraid you answered too quickly without taking a look in the link I brought before. CSS might be part of the solution here but there is more - the article is using javascript to be printed which find the width and height of the 3 columns and calculates the font size and how many words can be printed in the layout. You are also able to move between pages in the article. Although the whole article is places in one <div> the page's javascript makes calculation and prints it very nicely.

Go have a look!

mwinter
01-15-2006, 11:55 PM
The Herald is a terrible site which breaks utterly when client-side scripting is disabled. Don't try to emulate it.

Mike