Forum Moderators: not2easy

Message Too Old, No Replies

How to do you set up the line length to 60 characters for articles?

How do you do that? what tool do you use

         

vitalcoaching

6:36 pm on Nov 28, 2006 (gmt 0)

10+ Year Member



Hi,

I am struggling with this very simple issue.

How to do you set up the line length to 60 characters for articles?

Is there a simple free tool online or maybe some function in words which does that easily?

I tried with Word and with Notepad without success so far. When I fix a certain line length with Word and save it to txt file, it transforms the 3 or 4 lines paragraph into one line...

I would appreciate a couple of hints on how to do this effectively

Thanks

Francisco

auzer

3:43 pm on Dec 6, 2006 (gmt 0)

10+ Year Member



It would really depend where you intend on using the text. For non-web use you might actually need the line returns, so some kind of generator would be best. For web-based use you might need a script or function to actually handle the formatting at the time of display.

For most Internet-based applications a specific width is set. Are you considering the fact that everyone may not be using the same font or font size? There are many other considerations.

I did at one time write a pretty simple application to do this in PHP but am not sure if you have the resources to make use of it. Could you be a bit more specific about your application?

Regards,
Auzer

londrum

9:53 pm on Dec 22, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



i know there are probably lots of reasons why you might want a line length of 60 characters, but are you trying to get all the lines the same length?
if so, then it won't work as 99% of fonts use characters with different widths. a 'w' isn't the same width as in 'i', for example.
they will only turn out the same length if you use a monospace font like courier but that would look rubbish.

if you want lines to be the same length, and don't want to use PHP, then the easiest thing to do is just to use the ­ character.
stick it in middle of long words, and the word will split at that point. for example, if the word 'shakespeare' comes near the end of a line and you write
shakes­peare
then it will appear on the screen as
shakes-
peare
just like it does in newspapers and books.

bordering

9:37 pm on Dec 24, 2006 (gmt 0)

10+ Year Member



I had a need for a way to limit the character count of lines in an include which displays content on a web page, and found a UDF [user defined function] which does this, without breaking words, filename wrappit.cfm, on a site where simple Coldfusion UDFs are freely available.

That's obviously CF-specific, but there are probably chunks of ASP and PHP code out there which do the same thing.