Can Magento integrate with CakePHP?

Can Magento be integrated with CakePHP? If my site is developed in CakePHP. Can I make a product module, including a shopping cart in Magento?

+5
source share
3 answers

Yes it is possible. For instance:

require_once 'app/Mage.php';
umask(0);

Mage::app();
Mage::getSingleton('core/session', array('name'=>'frontend'));

$cart = Mage::helper('checkout/cart')->getCart()->getItemsCount();
echo 'Items count: ' . $cart;

Take a look at these articles:

http://www.exploremagento.com/magento/run-magento-code-outside-of-magento.php

http://blog.chapagain.com.np/magento-how-to-run-magento-code-in-an-external-website/

+9
source

Mage php- . , CakePHP . magento, , cakephp - ( , ), magento ( )

0

( , ).

" __()" 93 Magento app/code/core/Mage/Core/functions.php

    if (!function_exists('__')) {
        function _ () { .... }
    }

"DS" app/Mage.php 23

    if(!defined('DS')) {}

Mage Megento.

0

All Articles