Magento libararies based on Yii best practices