RE: end of line

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Try this: http://photomatt.net/scripts/autop

This is a "smart" function that wraps content with <p> tags.  It will translate 1 line break into a <br /> and two new lines translates as a new paragraph.  There's also an extended version that smartly handles block level elements.

--Nicole

---------------------------
Nicole Swan
Web Programming Specialist
Carroll College CCIT
(406)447-4310


-----Original Message-----
From: michael [mailto:michael@xxxxxxxxxxxxx]
Sent: Sunday, August 29, 2004 11:34 PM
To: php-db@xxxxxxxxxxxxx
Subject:  end of line


Hi. I'm trying to find a simple way to allow a client to update a "notes" page on her site whenever she wants. I created a form which allows her to save a few paragraphs to a mysql table. What I want to do, though, is write her paragraphs to an html page so others can see her words. Is there a way to replace newlines with <p> tags, so that her carriage returns show up as separate paragraphs when I write it to html? Also, she uses a mac - doesn't mac register newlines and carriage returns different than windows or unix? Thanks in advance. 

-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[Index of Archives]     [PHP Home]     [PHP Users]     [Postgresql Discussion]     [Kernel Newbies]     [Postgresql]     [Yosemite News]

  Powered by Linux