Skip to main content

Using forms and Pages in iFrames - Knowledgebase / Documentation - Deployteq Support

Using forms and Pages in iFrames

Authors list

Introduction

To keep customer data up-to-date you (possibly) use an update page. A form where customers can update their own information - such as email address. You can make this page part of an entire campaign in Deployteq, so that customers can always access their own data. But then of course you want all of this to become a seamless part of your own website. We briefly explain how you can best do this.

Note: This principle also applies to a logout page, but in this example we will assume an update page.

Nesessities

What do you need? First of all, a page on your own website where the entire process will take place. We take as an example: "https://www.yourdomain.nl/bijwerken" and an update page in Deployteq. This page must contain an iframe in which the Deployteq campaign is placed. We will not discuss here how you can best do this, but you can realize this with javascript or through a server-side script such as PHP. Next thing needed is a link from the email to the update page. After clicking "update" from the email, the customer should arrive at the update page. But only the link to the page "https://www.yourdomain.nl/bijwerken" is insufficient. Deployteq does not know who the customer is who appears on that update page. And without customer data, no update form can be displayed. That customer data must therefore be included.

Step 1: 'send' customer data

Customer data is sent with a click by adding a campaign object link as a variable to the url to the update page. For example: http://www.yourdomain.nl/bijwerken?Deployteq_url=rekenettableobjectlink name = 'unsubscribe' campaignid = '10 'objectid =' 2 'fl owid =' 0 '}}

<a href="http://www.uwdomein.nl/bijwerken?Deployteq_url={{objectlink name='Afmelden' campaignid='10' objectid='2' flowid='0'}}">de link</a>

The URL to the update page is followed by a question mark. After the question mark, the variable comes with a value. The name of the variable is, in this example, 'Deployteq_url'. The value is a campaign object link. That campaign object link results in a myDeployteq.com url with customer data and the Deployteq update campaign data.

Step 2: Integrate the update page into your website

Now the i-frame must be filled with that myDeployteq.com url. This requires a function that extracts and validates the myDeployteq.com url in order to place it in the src = ”” attribute of the i-frame. Such a function can be written in, for example, PHP or Javascript.

As mentioned, the function must validate the value of the variable "Deployteq_url". The validation must check whether the variable contains a URL and whether the URL is actually a myDeployteq.com URL. When this is not the case, due to a user manually changing the value of the variable "Deployteq_url", unexpected results may be shown in the i-frame.

When the script has validated the URL, the Deployteq URL is written in the src attribute of the iframe. In this way, the correct update or unsubscribe campaign with customer data is loaded into the iframe. e-Village has a javascript function available which you can use for this. This function validates the variable "Deployteq_url" and it is possible to specify a "default" value when the validation fails so that nothing is ever shown in the i-frame that is unwanted.

An example explaining this function can be found in the supplied file “setFrame_v3.html”. If you use a CMS and do not have access to the head and / or the body tag, you can NOT use this version of the javascript solution. Instead, use the solution in the document “setFrame_alternatief.html”.