imi_99 Posted April 17, 2008 Share Posted April 17, 2008 Hello, I am coming across another issue in text boxes. Issue is if i enter some text in text box field (in administration page if i enter some text in form then it shows text on main pages website) and press enter tab then cursor jump in a new line or if press enter tab twice (on keyboard) then it will show two line difference in input text box field. Like here <textarea class="input" name="os_text" cols="79" rows="27" ></textarea> When I submit and save this into database and show text on main website then text wont show tab difference and show all text in one line without any paragraph. Is there any solution for this. thanks Quote Link to comment https://forums.phpfreaks.com/topic/101528-text-box-issue/ Share on other sites More sharing options...
haku Posted April 17, 2008 Share Posted April 17, 2008 nl2br. This converts all new lines to < br /> tags. Quote Link to comment https://forums.phpfreaks.com/topic/101528-text-box-issue/#findComment-519317 Share on other sites More sharing options...
imi_99 Posted April 17, 2008 Author Share Posted April 17, 2008 nl2br. This converts all new lines to < br /> tags. Brilliant. It solved my problem. Quote Link to comment https://forums.phpfreaks.com/topic/101528-text-box-issue/#findComment-519332 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.