Skip to content

rife.render.ShortenUrl

Erik C. Thauvin edited this page Mar 19, 2023 · 5 revisions

Shortens a template value using is./gd.

The value must a valid http or https URL.

Based on isgd-shorten.

Usage

<!--v render:rife.render.ShortenUrl:valueId/-->
{{v render:rife.render.ShortenUrl:valueId/}}

Sample

Template

<a href="{{v render:rife.render.ShortenUrl:link/}}"><!--v link/--></a>

Code

template.setValue("link", "https://example.com/example");

Output

<a href="https://is.gd/vTQ9xs">https://example.com/example</a>