![]() |
Printing Doctrine Objects
When I first started working with X-cart 5, I had no idea how to print the contents of objects to the screen. Just now I forgot and had to go look it up again... :-)
X-cart 5 is not just OOP PHP vs Procedural PHP, it also utilizes Doctrine for working with the DB.Those unfamiliar with Doctrine can have a hard time! Sharing it here for all that are looking: print_r($entity); Should be actually: \Doctrine\Common\Util\Debug::dump($entity); Taken from: http://www.davelachapelle.ca/2013/01/25/dumping-doctrine-entities-without-print_r/ |
All times are GMT -8. The time now is 10:20 AM. |
Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.