Linux · January 17, 2019 0

Magento 1.x get dir

Mage::getBaseDir(‘base’);
'/Users/username/Sites/magento1point4.1.dev'

Mage::getBaseDir(‘app’);
/app/

Mage::getBaseDir(‘code’);
/app/code

Mage::getBaseDir(‘design’);
/app/design

Mage::getBaseDir(‘etc’);
/app/etc

Mage::getBaseDir(‘lib’);
/lib

Mage::getBaseDir(‘locale’);
/app/locale

Mage::getBaseDir(‘media’);
/media

Mage::getBaseDir(‘skin’);
/skin

Mage::getBaseDir(‘var’);
/var

Mage::getBaseDir(‘tmp’);
/var/tmp

Mage::getBaseDir(‘cache’);
/var/cache

Mage::getBaseDir(‘log’);
/var/log

Mage::getBaseDir(‘session’);
/var/session

Mage::getBaseDir(‘upload’);
/media/upload

Mage::getBaseDir(‘export’);
/var/export

Mage::getModuleDir('', 'Packagename_Modulename') );
Mage::getModuleDir('etc', 'Packagename_Modulename') );

var_dump( Mage::getModuleDir('controllers', 'Packagename_Modulename') );
var_dump( Mage::getModuleDir('sql', 'Packagename_Modulename') );
var_dump( Mage::getModuleDir('locale', 'Packagename_Modulename') );