34,333
edits
Changes
→Creating a Variable in PHP
Let's look at some valid and invalid PHP variable names:
<pre>
$_myName // valid
$myName // valid
$__myvar // valid
$myVar21 // valid
$_1Big // invalid - underscore must be followed by a letter
$1Big // invalid - must begion with a letter or underscore
$_er-t // invalid contains non alphanumeric character (-)
</pre>