A Little Noise


Static Variable Variables

  class A {
    static function b() {
      echo "It works\n";
  $theClass = "A";
  $x = new $theClass;

  /* Are any of the following legal? Which? */


Show Answer ▼

Comments (1) Trackbacks (0)
  1. Have you actually tried running this? All three work. =b

Leave a comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.

No trackbacks yet.