php 7.4 create new object class scope code example Example: declare variable in php class <?php class SimpleClass { public $var1 = 'hello'; } ?>