Magento / PHP · March 21, 2017 0

Magento get dirs

Base Dir

/htdocs/magento

Mage::getBaseDir('base');

App Dir

/app/

Mage::getBaseDir('app');

Code Dir

/app/code

Mage::getBaseDir('code');

Design Dir

/app/design

 Mage::getBaseDir('design');

ETC Dir

/app/etc

Mage::getBaseDir('etc');

Lib Dir

/lib

Mage::getBaseDir('lib');

Locale Dir

/app/locale

Mage::getBaseDir('locale');

Media Dir

/media

Mage::getBaseDir('media');

Skin Dir

/skin

Mage::getBaseDir('skin');

Var Dir

/var

Mage::getBaseDir('var');

Tmp Dir

/var/tmp

Mage::getBaseDir('tmp');

Cache Dir

/var/cache

Mage::getBaseDir('cache');

Log Dir

/var/log

Mage::getBaseDir('log');

Session Dir

/var/session

Mage::getBaseDir('session');

Upload Dir

/media/upload

Mage::getBaseDir('upload');

Export Dir

/var/export

Mage::getBaseDir('export');

Module Specific Directories

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