Creating A New Line In $body Of PHP Mail Function

后端 未结 6 853
感情败类
感情败类 2021-01-02 07:50

I\'ve got the PHP mail(): function working for a form I\'m using on my site. I am now trying to format the $body attribute to look nicer and more organized when I receive th

6条回答
  •  长情又很酷
    2021-01-02 08:21

    You must place \n in double quotes " not between single quotes ' If you want that this sequence would be interpreted as a new line (line feed 0x0A) character

    Take a look at this php documentation:

    http://php.net/manual/en/language.types.string.php

提交回复
热议问题