I'm trying to generate custom Breadcrumbs in a SilverStripe app and I can't figure out why the links are not working. The HTML code in page source appears to be what I want and if I click on a link from the elements section of Safari's webpage inspector, I can land on the correct page. However, when I hover over the link or click on any of my Breadcrumb links in the browser page, I always see localhost
and get directed to the homepage. Any ideas how to fix this?
Here's some relevant code
My template, Breadcrumbs.ss:
<% loop $MyBreadcrumbs %>
<a href="$url" title="$name">/ $name </a>
<% end_loop %>
The code below is HTML copied from Page Source. The links from this section all go to the root page, “/“, instead of, for example, "/resources/links/"
<div id="Breadcrumbs" class="grid_9 alpha">
<a href="/" title="Home">/ Home </a>
<a href="/resources/links/" title="Links">/ Links </a>
</div>
The links below all work and are generated using the $Link
SilverStripe common variable:
<div class="row">
<aside class="col-3 col-md-3 d-none d-md-block d-print-none">
<ul class="aside__nav">
<li>
<a href="/resources/links/" title="Links">Links</a>
</li>
</ul>
</aside>
</div>