PDA

View Full Version : replacing returns in saved data?


B&T
5-27-03, 06:13 PM
in a text entry box if a person types a return (new line) and you save that field, when read and redisplayed in html it is not there. but if the person types the html <br> you do get the break on redisplay.

so you should be able to search the string for the carriage return and replace them with <br> before you save the data? seems logical to me.

but before I go playing around with this . . . anyone solve this problem before?

Pig
5-27-03, 06:52 PM
check out nl2br()

B&T
5-27-03, 07:03 PM
just what I needed - thanks Pig