<?php foreach( $modules_list as $var ) { $this -> $var = $var::singleton( ); } ?>
Ma ktoś może pomysł jak obejść ten problem, bo oczywiście coś takiego jak $var::singleton( ); nie moze mieć miejsca...
<?php foreach( $modules_list as $var ) { $this -> $var = $var::singleton( ); } ?>
<?php // ... $this -> $var = $var::singleton( ); // ... ?>
<?php // ... $this->var = var::singleton( ); // ... ?>
<?php class myclass { function say_hello() { } } $classname = \"myclass\"; ?>
<?php foreach( $modules_list as $var ) { } ?>
<?php $this -> mod_test $this -> mod_test2 ?>
<?php $this -> mod_test = mod_test::singleton( ); ?>
<?php class idawell { private function __construct() { } { if ( $instance[$name] == null ) { $instance[$name] = new $name; } return $instance[$name]; } } ?>