note 39069 added to function.print

From: Date: Thu, 15 Jan 2004 21:08:13 +0000
Subject: note 39069 added to function.print
Groups: php.notes 
Request: Send a blank email to php-notes+get-63656@lists.php.net to get a copy of this message
To elaborate on above example adding an array variable $text = <<<END This uses the "here document" syntax to output multiple lines with $variable interpolation. Note that the here document terminator must appear on a line with just a semicolon no extra whitespace! User = {$_REQUEST['user']} END; 'print $text;' Will output the string. Very handy for storing HTML. Or adding {} around the array will allow you to use above mentioned html blocks in conjuction with forms. Tip found on http://justinvincent.com/home/articles.php?articleId=8&page=5 Rene =<>= ---- Manual Page -- http://www.php.net/manual/en/function.print.php Edit -- http://master.php.net/manage/user-notes.php?action=edit+39069 Delete -- http://master.php.net/manage/user-notes.php?action=delete+39069&report=yes Reject -- http://master.php.net/manage/user-notes.php?action=reject+39069&report=yes Search -- http://master.php.net/manage/user-notes.php

« previous php.notes (#63656) next »