Author:
TwistedInteractive
Version:
1.1
Released:
15 May 2012
Category:
Field Types

Browse

Description

Unique link field

Please note: for Symphony lower than 2.3, use the 1.0-tag

This extension allows you to create a link to an unique URL, for example: when you want to send someone an e-mail with a link which is only valid for 24 hours.

How does it work?

Simply add the field to your section. You can set the following parameters - The link, with 2 parameters: [URL] and [CODE]. So something like [URL]/signup/[CODE]/ would translate to http://www.domain.com/signup/1421d689f8a0c388efaa59d2c16390f048677c44/. - How many hours the link will be valid (defaults to 24 hours). - Check whether the entry should be deleted as soon as the link is no longer valid.

So how can I use this in my site then?

Simply create a page with a parameter called code (for example) and add a datasource with the unique field link to it.

Next, use some XSL logic. For example, something like this:

<xsl:choose>
    <xsl:when test="$code = my-datasource/entry/link/@code">

        <!-- The code is valid! Show some content, form, etc... -->

    </xsl:when>
    <xsl:otherwise>

        <!-- The code is not valid! Show some error message or something -->

    </xsl:otherwise>
</xsl:choose>

Repository

https://github.com/TwistedInteractive/field_unique_link

Discuss this Extension

Compatibility

2.7.10 Unsure
2.7.9 Unsure
2.7.8 Unsure
2.7.7 Unsure
2.7.6 Unsure
2.7.5 Unsure
2.7.4 Unsure
2.7.3 Unsure
2.7.2 Unsure
2.7.1 Unsure
2.7.0 Unsure
2.6.11 Unsure
2.6.10 Unsure
2.6.9 Unsure
2.6.8 Unsure
2.6.7 Unsure
2.6.6 Unsure
2.6.5 Unsure
2.6.4 Unsure
2.5.4 Unsure

Symphony • Open Source XSLT CMS

Server Requirements

  • PHP 5.3-5.6 or 7.0-7.3
  • PHP's LibXML module, with the XSLT extension enabled (--with-xsl)
  • MySQL 5.5 or above
  • An Apache or Litespeed webserver
  • Apache's mod_rewrite module or equivalent

Compatible Hosts

Sign in

Login details