How to integrate magento and wordpress
January 11, 2014
You want to integrate your store to blog.simply follow my simple steps.
Step 1:
Goto magneto store files edit index.php add these lines
if ( strpos($_SERVER['REQUEST_URI'], 'index.php/admin') === FALSE )
{
define('WP_USE_THEMES', false);
require_once('../wp-load.php'); // configure your WordPress location.
}
Step 2:
copy "Your-magento-folder/app/code/core/Mage/Core/functions.php"
to "Your-magento-folder/app/code/local/Mage/Core/functions.php"
If u not have the folder structure create that folder and paste .
Step 3:
find "function __() " this line around 90 to 100 in "Your-magento-folder/app/code/local/Mage/Core/functions.php"
thats look like
"
function __()
{
return Mage::app()->getTranslator()->translate(func_get_args());
}
"
U change it like this
"
if (!function_exists('__')) {
function __()
{
return Mage::app()->getTranslator()->translate(func_get_args());
}
}
"