Discover new line in textarea php, include the articles, news, trends, analysis and practical advice about new line in textarea php on alibabacloud.com
Today, I encountered a textarea line feed problem in the project, which was not solved after debugging for half a day. You need to convert the carriage return text in textarea into a br and store it in the database. The following is my solution to
I recently studied discuz and found that many backend settings are filled in with textarea and each row is interesting, avoid wasting too much time on the control issues during the settings. Let's just move on to the code: $ namesn... I recently
Here is my solution to the problem, and finally I understand it, it's a sewer that almost capsized
1. You must know that the line break in TextArea is \ n (personal detection found that pressing ENTER is \ n, as if it were \ r \ n under Linux)
2.
Today, I encountered a textarea line feed problem in the project, which was not solved after debugging for half a day. You need to convert the line breaks in textarea into and save them to the database.
The following is my solution to this
The code is as follows
$names = Preg_split ('/rn/', $_post[' textarea '));foreach ($names as $name) {Todo something Eg:echo $name;}
The value is very simple, then the assignment, in the TEXTAREA output line break is not so
Nothing left to worry about. I saw an article on php form conversion textarea line break on the Internet. After reading the article, I feel that some information in this article is not accurate based on my past experience... as a result, I
The following is my solution to this problem. At last, I fully understood it. It was a real risk of turning around the ship.
1.You must know that the linefeed in textarea is \ n (I found that the Enter key is \ n, as if it is \ r \ n in
The following is my solution to this problem. At last, I fully understood it. It was a real risk of turning around the ship.
1.You must know that the linefeed in textarea is \ n (I found that the Enter key is \ n, as if it is \ r \ n in
Use php to write your own blog program on sinaappengine. When creating or updating an article, you can use textarea to store the article content. Currently, the article content is saved to the database in plain text format. The form is like this (in
Nothing left to worry about. I saw an article on php form conversion textarea line break on the internet. after reading the article, I feel that some information in this article is not accurate based on my past experience... as a result, I
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.