Run a Magento Code out of installation folder

0 votes
437 views
asked Jun 22, 2016 in Magento by Annabelle
How can we run Magento Code Externally on another folder other than its default installation folder please?

1 Answer

0 votes
answered Jun 29, 2016 by Narayanan

Simple as this.

<?php
require_once('app/Mage.php'); //Path to Magento
umask(0);
Mage::app();
// Run you code here
?>

Related questions

+2 votes
1 answer 292 views
+1 vote
1 answer 454 views
0 votes
1 answer 232 views
+1 vote
1 answer 205 views
0 votes
1 answer 361 views
+2 votes
0 answers 234 views
...