After some research I’ve found no native solution, but I can’t believe that something like that isn’t included in yii.
Is there another simple yii-style-way instead of using an extension?
After some research I’ve found no native solution, but I can’t believe that something like that isn’t included in yii.
Is there another simple yii-style-way instead of using an extension?
Check this out…
Convert Model With Relations To Php Array And Json
I’m using Restfull Yii; which contains this functionality itself.
As i am aware there seems no native class to do it.
You can use http://jmsyst.com/bundles/JMSSerializerBundle to encode to JSON.