Overriding the delimiter (the character that seperates links) in primary/secondary links
Description
This snippet is useful if you just want to override the default delimiter character on primary/secondary links. The delimiter is the character that seperates links.
For example: HOME ¦ NEWS ¦ SEARCH ¦ CONTACT.
Where delimiter = ¦
Notes
- For use within your page.tpl.php file.
- Change the $link_delimiter value to what you want
- Please discuss or suggest tips at this thread on the forum discussing how to customise primary/secondary links
<div id="navigation">
<?php if ($links['primary']) : ?>
<ul id="main-nav">
<?php
$link_delimiter = '|'; // Change this to what you want the links seperated by
$delimiter = '</li>' . $link_delimiter . '<li>';
print '</li>' . implode($delimiter, $links['primary']) . '</li>';
?>
</ul>
<?php endif; ?>
</div>