viewing paste Unknown #14452 | PHP

Posted on the
1 2 3 4 5 6 7 8
<?php
 
$obj = (object) array('foo' => 'bar', 'property' => 'value');
 
echo $obj->foo; // prints 'bar'
echo $obj->property; // prints 'value'
 
?>
Viewed 267 times, submitted by unknown.