bobohob Posted December 12, 2007 Share Posted December 12, 2007 I found it's a hassle to code html inside php, for example when you compose a message for email : $message = "<b>................... ............. ......... ........</b>"; is there a better/convenient method ? Thank you in advance. Quote Link to comment Share on other sites More sharing options...
rajivgonsalves Posted December 12, 2007 Share Posted December 12, 2007 you can use the heredoc string $message = <<< MARK .... ..... ..... MARK; more information at http://php.net/manual/en/language.types.string.php#language.types.string.syntax.heredoc Quote Link to comment Share on other sites More sharing options...
dsaba Posted December 12, 2007 Share Posted December 12, 2007 only hard thing about mixing html with PHP is escaping quotes $var = "<html attrib=\"lala\" />"; concatenation is easy "string".php."string" Quote Link to comment 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.