note 27201 added to function.return

From: Date: Wed, 27 Nov 2002 04:05:31 +0000
Subject: note 27201 added to function.return
Groups: php.notes 
Request: Send a blank email to php-notes+get-40019@lists.php.net to get a copy of this message
Another note that isn't mentioned above is that return() seems to be able to be used exactly like print() and echo() and other similar commands/constructs. For example you can return something like: return <<<TEXT this is a bunch of text i want to return, it even have <b>html</b> in it and some $variables. you can also hit enter and it will return the newlines as well. excellent for returning a block of html or other text and assigning it to a variable for inclusion later on. TEXT; -- http://www.php.net/manual/en/function.return.php http://master.php.net/manage/user-notes.php?action=edit+27201 http://master.php.net/manage/user-notes.php?action=delete+27201 http://master.php.net/manage/user-notes.php?action=reject+27201

« previous php.notes (#40019) next »