Custom Templates

If you are using custom templates, you will need to update these to use 3D Secure V2. We've prepared a new kit which you can adapt, and provided some instructions below. You may need to speak to your inhouse IT department, web developer and/or partner who helped you set up your payments page.

Instructions

1. Download the latest custom template kit on the from here:

2. Add the 3d_callback.v2.xslt and 3d_redirect_v2.xslt files to your custom templates folder. These template files won't need to be customised.

3. You'll need to add the card_authentication_v2.xslt template to your custom templates folder and make your changes to it. You can use your 3DSv1 version of the templates (card_authentication.xslt) as an example. The unaltered version of the 3DSv1 template is identical to the 3DSv2 version except for the <form> parameters. The following changes will need to be made.

This:

<form name="form" action="" method="POST">
<xsl:attribute name="action"><xsl:value-of select="payment-model/pareq-env/acsurl"/></xsl:attribute>
<noscript>
<center>
<p><xsl:value-of select="$i18n/multi-lingual-text/texts[lang($requiredlang)]/text[@label='click_btn_below']"/>
</p>
<input type="submit" value="Go"/>
</center>
</noscript>
<input type="hidden" name="PaReq">
<xsl:attribute name="value"><xsl:value-of select="payment-model/pareq-env/pareq"/></xsl:attribute>
</input>
<input type="hidden" name="TermUrl">
<xsl:attribute name="value"><xsl:value-of select="payment-model/pareq-env/termurl"/></xsl:attribute>
</input>
<input type="hidden" name="MD">
<xsl:attribute name="value"><xsl:value-of select="payment-model/pareq-env/md"/></xsl:attribute>
</input>
</form>

Needs to be altered to:

<form name="form" action="" method="POST">
<xsl:attribute name="action"><xsl:value-of select="payment-model/creq-env/acsurl"/></xsl:attribute>
<noscript>
<center>
<p><xsl:value-of select="$i18n/multi-lingual-text/texts[lang($requiredlang)]/text[@label='click_btn_below']"/>
</p>
<input type="submit" value="Go"/>
</center>
</noscript>
<input type="hidden" name="creq">
<xsl:attribute name="value"><xsl:value-of select="payment-model/creq-env/creq"/></xsl:attribute>
</input>
<input type="hidden" name="threeDSSessionData">
<xsl:attribute name="value"><xsl:value-of select="payment-model/creq-env/threeDSSessionData"/></xsl:attribute>
</input>
</form>

 

4. Add the following script block at the bottom of card_details.xslt, just before </body>:

<script>
populate3dsFields();
</script> 

Next steps

You will need to test the templates locally and ensure they function corrrectly with javascript enabled and disabled. Once you are happy with them, simply zip the XSLT and YourImages folder and email them, along with your vendor name to templates@opayo.io.