Skip to content
Permalink
Browse files

Migrate crumbs to a function

  • Loading branch information...
Quy committed Feb 22, 2019
1 parent b5f0696 commit f82e65dce8c62c3f2f71e578889ed3c3b89dbd09
Showing with 8 additions and 10 deletions.
  1. +8 −10 viewtopic.php
@@ -186,6 +186,12 @@
else if ($pun_config['o_feed_type'] == '2')
$page_head['feed'] = '<link rel="alternate" type="application/atom+xml" href="extern.php?action=feed&amp;tid='.$id.'&amp;type=atom" title="'.$lang_common['Atom topic feed'].'" />';
$crumbs = generate_crumbs(array(
array($lang_common['Index'], 'index.php'),
array(pun_htmlspecialchars($cur_topic['forum_name']), 'viewforum.php?id='.$cur_topic['forum_id']),
array(pun_htmlspecialchars($cur_topic['subject']), 'viewtopic.php?id='.$id),
));
$page_title = array(pun_htmlspecialchars($pun_config['o_board_title']), pun_htmlspecialchars($cur_topic['forum_name']), pun_htmlspecialchars($cur_topic['subject']));
define('PUN_ALLOW_INDEX', 1);
define('PUN_ACTIVE_PAGE', 'index');
@@ -194,11 +200,7 @@
?>
<div class="linkst">
<div class="inbox crumbsplus">
<ul class="crumbs">
<li><a href="index.php"><?php echo $lang_common['Index'] ?></a></li>
<li><span&#160;</span><a href="viewforum.php?id=<?php echo $cur_topic['forum_id'] ?>"><?php echo pun_htmlspecialchars($cur_topic['forum_name']) ?></a></li>
<li><span&#160;</span><strong><a href="viewtopic.php?id=<?php echo $id ?>"><?php echo pun_htmlspecialchars($cur_topic['subject']) ?></a></strong></li>
</ul>
<?php echo $crumbs ?>
<div class="pagepost">
<p class="pagelink conl"><?php echo $paging_links ?></p>
<?php echo $post_link ?>
@@ -409,11 +411,7 @@
<p class="pagelink conl"><?php echo $paging_links ?></p>
<?php echo $post_link ?>
</div>
<ul class="crumbs">
<li><a href="index.php"><?php echo $lang_common['Index'] ?></a></li>
<li><span&#160;</span><a href="viewforum.php?id=<?php echo $cur_topic['forum_id'] ?>"><?php echo pun_htmlspecialchars($cur_topic['forum_name']) ?></a></li>
<li><span&#160;</span><strong><a href="viewtopic.php?id=<?php echo $id ?>"><?php echo pun_htmlspecialchars($cur_topic['subject']) ?></a></strong></li>
</ul>
<?php echo $crumbs ?>
<?php echo $subscraction ?>
<div class="clearer"></div>
</div>

0 comments on commit f82e65d

Please sign in to comment.
You can’t perform that action at this time.