If the method they use to "upload" involves pasting
the text into an HTML textbox, I usually do this:
replace all occurances of \n with <br>.

Look into the ereg_replace() function in the manual or
at php.net for more info, but that is some limited
formatting.

If you need further formatting, like someone else
pointed out, you'll need to post more info.


--- David Robley <[EMAIL PROTECTED]> wrote:
> In article
> <[EMAIL PROTECTED]>,
> [EMAIL PROTECTED] 
> says...
> > I have a field in a form which allows user to
> upload thier biographys.Once
> > they upload a bunch of texts,the script I wrote
> automatically show it on a
> > webpage, however, the contents are all scrambled
> toghther without line break
> > and formatting..
> > How am I able to show the formatted outputs?
> > 
> > I tried to use <pre> </pre>, but it didn't work
> well.
> > 
> > Any suggestions?
> 
> For linebreaks, see nl2br(). In respect of
> formatting, you would only 
> expect html tags to be rendered by a browser - if
> you mean some other kind 
> of formatting, perhaps you could provide further
> information.
> 
> -- 
> David Robley
> Temporary Kiwi!
> 
> Quod subigo farinam
> 
> -- 
> PHP Database Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
> 


__________________________________________________
Do You Yahoo!?
HotJobs - Search Thousands of New Jobs
http://www.hotjobs.com

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

Reply via email to