<div class="xpath-widget" i18n:domain="xmldirector.plonecore">
    <label i18n:translate="">XPath expression:</label>
    <span tal:content="view/xpath_expression" />
    <br/>
    <tal:def define="result view/xpath_evaluated">
        <tal:if condition="result/errors">
            <label i18n:translate="">Errors</label>
            <ul> 
                <li tal:repeat="error result/errors"
                    tal:content="error"
                />
            </ul>
        </tal:if>
        <tal:if condition="not: result/errors">
            <label i18n:translate="">XPath result:</label>
            <span tal:content="result/data" />
        </tal:if>
    </tal:def>
</div>

