note 126012 deleted from language.basic-syntax.phpmode by mazzanet

From: Date: Sun, 18 Apr 2021 06:35:20 +0000
Subject: note 126012 deleted from language.basic-syntax.phpmode by mazzanet
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-216299@lists.php.net to get a copy of this message
Note Submitter: coder at fishlet dot com ---- I find the notion that PHP "starts parsing" inside a <?php ... ?> tag, and "just passes through" everything outside a tag, to be a confusing oversimplification and generally wrong. For example, this code would be inexplicable: <?php for ($i = 0; $i < 10; $i++) { ?> Repeated<br> <?php } ?> I think a better way to look at it is that the PHP parser turns any text NOT inside a <?php ... ?> tag into an implicit echo statement that is embedded at the corresponding place in the code.

« previous php.notes (#216299) next »