以连接跳转到一个cms page为例:
在phtml文件中:
<a href="<?php echo $this->getUrl('')?>some page">网址+some page </a>
红色<?php echo $this->getUrl(”)?>为获得网站网址,蓝色字为页面的SEF URL Identifier
在cms的page或者block中:
<a href="{{store url=''}}about-us/">网址+About bagandcart.com</a>
所以这个<?php echo $this->getUrl(”)?> 与{{store url=”}} 动态获得网址是很有用的
转载标明出处: hellokeykey.com 右兜钥匙
<?php echo $this->getUrl('')?> 老大 这句话 是获取 magento 根目录吧?
文章 我转走了。
是网址,不要想成根目录为好,想成是magento网站的根网址
恩 我也是那个意思。就是网址。。