XF 2.0 Current URL?

{$xf.uri} seems to return
/posts/108/share?_xfRequestUri=title&_xfWithData=1&_xfToken=xx&_xfResponseType=json

(witch sounds like full uri instead of uri?)

Can this somehow shortened to /posts/108/?

Edit:
This is happening only in following code:
HTML:
<xf:macro name="share_clipboard_input" arg-label="!" arg-text="!" arg-successText="">
    <xf:css src="share_controls.less" />

    <xf:set var="$id">{{ unique_id() }}</xf:set>

    <div class="shareInput" data-xf-init="share-input" data-success-text="{$successText}">
        <xf:if is="$label">
            <label class="shareInput-label" for="{$id}">{$label}</label>
        </xf:if>
        <div class="inputGroup inputGroup--joined">
            <div class="shareInput-button inputGroup-text js-shareButton is-hidden"
                data-xf-init="tooltip" title="{{ phrase('copy_to_clipboard')|for_attr }}">

                <i></i>
            </div>
            <xf:textbox class="shareInput-input js-shareInput"
                value="our.short.link{$xf.uri}" readonly="true" id="{$id}" />
        </div>
    </div>
</xf:macro>

This is working in following code:
HTML:
<xf:if is="$xf.options.linkShare AND !$hideLink">
    <a class="shareButtons-button shareButtons-button--link is-hidden" data-clipboard="our.short.link{$xf.uri}">
    <i></i>
    <span>{{ phrase('link') }}</span>
    </a>
</xf:if>
 
Last edited:
Back
Top Bottom