eval.in

Paste #3599

PHP — PHP 5.4.6, pasted 1 year ago

1
2
3
4
5
6
<?php

class varClassName {}

$className = 'varClassName';
$validator = new $className(array('min'=>2, 'max'=50));

Program Output

Parse error: syntax error, unexpected '=', expecting ')' in /tmp/execpad-242a786cf431/source-242a786cf431 on line 6

Exited with error status 255

Fork