Esempio n. 1
0
 /**
  * Return URL based on current selected directory or root directory for startup
  *
  * @return string
  */
 public function getCurrentUrl()
 {
     if ($this->_getMediaSymlinkHelper()->active()) {
         if (!$this->_currentUrl) {
             $path = str_replace(realpath(Mage::getConfig()->getOptions()->getMediaDir()), '', $this->getCurrentPath());
             $path = trim($path, DS);
             $this->_currentUrl = Mage::app()->getStore($this->_storeId)->getBaseUrl('media') . $this->convertPathToUrl($path) . '/';
         }
         return $this->_currentUrl;
     } else {
         return parent::getCurrentUrl();
     }
 }