Josua M C
Josua M C

Reputation: 3158

How to Magento getBaseUrl on Frontend from Backend?

My frontend url and backend url isn't the same.

example,

Frontend : http://magento.com/

Backend : http://my.magento.com/

then,

How to get the Frontend base url from Backend?

Upvotes: 1

Views: 5588

Answers (1)

Tim Bezhashvyly
Tim Bezhashvyly

Reputation: 9100

I don't have a store with customized admin area URL but I guess this shall work:

Mage::app()->getStore($storeId)->getBaseUrl(Mage_Core_Model_Store::URL_TYPE_LINK);

Upvotes: 5

Related Questions