<c:forEach var="agnBreadcrumb" items="${agnBreadcrumbs}">
    <c:set var="agnBreadcrumb" value="${agnBreadcrumb.value}"/>

    <c:if test="${not empty agnBreadcrumb.icon}">
        <c:set var="crumbs" scope="request">
            <li><i class="icon icon-${agnBreadcrumb.icon}"></i></li>
        </c:set>
    </c:if>

    <c:set var="crumb">
        <c:choose>
            <c:when test="${not empty agnBreadcrumb.textKey}">
                <mvc:message code="${agnBreadcrumb.textKey}"/>
            </c:when>
            <c:when test="${not empty agnBreadcrumb.text}">
                ${fn:escapeXml(agnBreadcrumb.text)}
            </c:when>
        </c:choose>
    </c:set>

    <c:if test="${not empty agnBreadcrumb.url}">
        <c:set var="crumb"><a href="${fn:trim(agnBreadcrumb.url)}">${fn:trim(crumb)}</a></c:set>
    </c:if>

    <c:set var="crumbs" scope="request">
        ${crumbs}
        <c:if test="${empty agnBreadcrumb.icon}">
            ${crumbSeparator}
        </c:if>
        <li><span>${fn:trim(crumb)}</span></li>
    </c:set>
</c:forEach>
