REGISTER
|
Search Tycoon Talk
|
Freelancer.com
|
Members
Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.
Register Here
Forum Rules
PHP Forum
You are currently viewing our PHP Forum as a guest. Please
register
to participate.
Login
Remember Me?
Login via Freelancer.com
Tycoon Talk
>
Web Development and Programming Support
>
PHP Forum
>
rendering \n\n
Link Back
Thread Tools
Search this Thread
rendering \n\n
11-02-2008, 10:45 AM
#
1
(
permalink
)
rendering \n\n
numbenator
Webmaster Talker
Posts: 523
Location: London
Trades:
0
Talkupation:
HI
I have a string i have extracted from a db field that contains "\n\n" representing carriage returns in the text.
How do i replace the "\n\n" with carriage returns in the text so as when i insert into a text area they render with the cr's
Cheers
Steve
__________________
Please login or register to view this content.
Registration is FREE
Register
now for full access!
11-02-2008, 11:01 AM
#
2
(
permalink
)
Re: rendering \n\n
chrishirst
Missing! presumed drunk.
Latest Blog Post:
A Simple DHTML Tabbed Interface
Posts: 42,385
Name: Chris Hirst
Location: Blackpool. UK
Trades:
0
Talkupation:
str_replace("\n\n",chr(13),$the_text)
__________________
Chris. ->>
Please login or register to view this content.
Registration is FREE
<<-
A foolish consistency is the hobgoblin of little minds
Thought for today:- Is SEO the only industry where all the cowboys are Indians?
11-02-2008, 01:25 PM
#
3
(
permalink
)
Re: rendering \n\n
tripy
Do not try this at home!
Latest Blog Post:
GooTrans, a cross-platform python frontend to Goog...
Posts: 3,621
Name: Thierry
Location: I'm the uber Spaminator !
Trades:
0
Talkupation:
or easier:
PHP Code:
$text
=
nl2br
(
$dbField
);
__________________
Only a biker knows why a dog sticks his head out the window.
« Reply to
rendering \n\n
Previous Thread
|
Next Thread
Tycoon Talk
>
Web Development and Programming Support
>
PHP Forum
>
rendering \n\n
Thread Tools
Search this Thread
Show Printable Version
Email this Page
Search this Thread
:
Advanced Search
Posting Rules
You
may not
post new threads
You
may not
post replies
You
may not
post attachments
You
may not
edit your posts
BB code
is
On
Smilies
are
On
[IMG]
code is
On
HTML code is
Off
Trackbacks
are
Off
Pingbacks
are
Off
Refbacks
are
Off
Forum Rules
Feeds:
RSS
JS
XML
Feeds for this forum:
RSS
JS
XML
LinkBack
LinkBack URL
About LinkBacks
Bookmark & Share
Digg this Thread!
Add Thread to del.icio.us
Bookmark in Technorati
Tweet this thread
Page generated in
0.11413
seconds with
12
queries