Z
Z
zk11342015-12-14 12:43:39
PHP
zk1134, 2015-12-14 12:43:39

How to remove a link from breadcrumbs?

There is a breadcrumb code:

<div id="crumbs breadcrumb">
<?
$i = 1;

if ($this->_tpl_vars['content']['tree_for_map']):
  $this->_foreach['f1'] = array('total' => count($_from = (array)$this->_tpl_vars['content']['tree_for_map']), 'iteration' => 0);
  if ($this->_foreach['f1']['total'] > 0):
    	foreach ($_from as $this->_tpl_vars['element']):
       		$this->_foreach['f1']['iteration']++;
         ?>

        <span itemscope itemtype="http://data-vocabulary.org/Breadcrumb"><a itemprop="url" href="<?php if ($this->_tpl_vars['element']['view_url'] == '/pages/index'): ?>/<?php else:  echo $this->_tpl_vars['element']['view_url'];  endif; ?>"><span itemprop="title"><?php echo $this->_tpl_vars['element']['name']; ?></span></a></span>


  <? if (! ($this->_foreach['f1']['iteration'] == $this->_foreach['f1']['total'])): ?> / <? endif;  endforeach; endif; unset($_from);  endif;
  echo ' / ' . $this->_tpl_vars['content']['name'];
 ?>
</div>

It looks like this on the page: joxi.ru/ZrJOkQQs194qjm
It is required to remove the link from the last paragraph (that is, from the paragraph to the current page)

Answer the question

In order to leave comments, you need to log in

1 answer(s)
U
Uwe_Boll, 2015-12-14
@Uwe_Boll

read the manual

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question