PHP 7.2.0 Beta 3 Released

Voting

Please answer this simple SPAM challenge: two minus two?
(Example: nine)

The Note You're Voting On

david at removethisbit dot futuresbright dot com
11 years ago
When using variable variables this is invalid:

<?php
$my_variable_
{$type}_name = true;
?>

to get around this do something like:

<?php
$n
="my_variable_{$type}_name";
${
$n} = true;
?>

(or $$n - I tend to use curly brackets out of habit as it helps t reduce bugs ...)

<< Back to user notes page

To Top