Written by Sean Behan on Sat Dec 02nd 2017

It's short and sweet.

$obj_from_array = (object)['key'=>'val'];

echo $obj_from_array->key;

Tagged with..
#php #array #object #snippet

Just finishing up brewing up some fresh ground comments...