对于我的面包屑,magento 1.9.x中不存在锚链接

时间:2017-07-20 09:37:09

标签: php magento coding-style magento-1.9

请查看 void YourLayerYouWantToSwallowTouches::addEvents() { auto listener = cocos2d::EventListenerTouchOneByOne::create(); listener->setSwallowTouches(true); listener->onTouchBegan = [&](cocos2d::Touch* touch, cocos2d::Event* event) { if (this->getBoundingBox().containsPoint(touch->getLocation())) { //touchBegan(touch); // You can call touchBegan() for that layer here return true; // to indicate that we have consumed touch. } return false; // we did not consume touch, pass thru. }; _eventDispatcher->addEventListenerWithSceneGraphPriority(listener, this); } 的代码:

breadcrumbs.phtml

帮我弄清楚为什么我的面包屑中没有锚链接,但文字即将到来。在这里,我看到代码与其他面包屑有些不同,代码是正确的。

2 个答案:

答案 0 :(得分:0)

//替换下面的代码并用基本文件检查或替换文件。

 <?php if($crumbs && is_array($crumbs)): ?>
    <!-- SLIDER START HERE-->
    <div class="container">
      <div class="innerSlider relative">

        <div class="innerSlidercontent">
          <h2>“People with thyroid problems avoid eating millet on a daily basis 
      as it is believed to contain some”</h2>
        </div>
        <div class="insideSlidePic"> <img src="<?php echo $this->getSkinUrl('images/barnyard_millet_bisi_belle_bhaat_recipe.jpg'); ?>"  
      alt=""> </div>
      </div>

      <div class="clear"></div>

      <ul class="routeMenu">
        <?php foreach($crumbs as $_crumbName=>$_crumbInfo): ?>
            <li class="<?php echo $_crumbName ?>">
            <?php if($_crumbInfo['link']): 

               if($_crumbInfo['title']=="Home"){
                $_crumbInfo['link']=Mage::getUrl();
            }
            ?>
                <a class="sc_hover" href="<?php echo $_crumbInfo['link'] ?>" 
    title="<?php echo $this->escapeHtml($_crumbInfo['title']) ?>"><?php echo 
   $this->escapeHtml($_crumbInfo['label']) ?></a>
            <?php elseif($_crumbInfo['last']): ?>
                <span><?php echo $this->escapeHtml($_crumbInfo['label']) ?>
      </span>
            <?php else: ?>
                <?php echo $this->escapeHtml($_crumbInfo['label']) ?>
            <?php endif; ?>
            <?php if(!$_crumbInfo['last']): ?>

            <?php endif; ?>
            </li>
        <?php endforeach; ?>
      </ul>
      </div>
      <div class="clear"></div>
      </div>

      <!-- SLIDER END HERE-->
       <?php endif; ?>

备用解决方案复制基本文件到您的custon设计路径如下。

app/design/frontend/base/default/template/page/html/breadcrumbs.phtml

copy from base to your custom design path.

app/design/frontend/your-package/your-theme/template/page/html/breadcrumbs.phtml

答案 1 :(得分:0)

请检查默认的magento主题。我认为breadcrumb会起作用。如果breadcrumb正在使用您的默认主题,请通过重命名布局和主题文件来检查您当前的自定义主题。