php clone object
snippet in php

php clone

user8393

//Copies an existing object
$objectA = clone $objectB;

php clone object

user2891

$objectB = clone $objectA;