Sunday, July 8, 2012

Magento all paths.


Mage::getBaseUrl() => Gets base url path e.g. http://my.website.com/
Mage::getBaseUrl(‘media’) => Gets MEDIA folder path e.g. http://my.website.com/media/
Mage::getBaseUrl(‘js’)                => Gets JS folder path e.g. http://my.website.com/js/
Mage::getBaseUrl(‘skin’)              => Gets SKIN folder path e.g. http://my.website.com/skin/
Mage::getBaseDir()             => Gives you your Magento installation folder / root folder e.g. /home/kalpesh/
Mage::getBaseDir(‘app’)             => Gives you your Magento’s APP directory file location e.g. /home/kalpesh/
Mage::getBaseDir(‘design’)            => Gives you your Magento’s DESIGN directory file location e.g. /home/kalpesh/wo
Mage::getBaseDir(‘media’) => Gives MEDIA directory file path
Mage::getBaseDir(‘code’) => Gives CODE directory file path
Mage::getBaseDir(‘lib’) => Gives LIB directory file path
Get Current URL – whole URL path
Mage::helper(‘core/url’)->getCurrentUrl()

No comments:

Post a Comment

Please mention your comments.......