Developer forum

Forum » Rapido » Send E-mail with unique code

Send E-mail with unique code

Gerard Kocks
Gerard Kocks
Reply

Hi,

For a new customer we need to find out if it is possible to send a user an unique code by mail.
Codes need to be generated by our customer and imported in Dynamic Web.

Can someone please tell me which options we have?

Best regards
Gerard


Replies

 
Karsten Thuen Dynamicweb Employee
Karsten Thuen
Reply

Hi Gerard

I do not think there is special method for this in Dynamicweb. By unique code, do you really mean a unique ID? If so. What I would do is, create a custom form template and set it up with "Forms for editors". Then create a hidden field that holds the unique ID. 

I think you could look at c# for generating the ID. This may help you: https://madskristensen.net/blog/generate-unique-strings-and-numbers-in-c/

But if your customer actually creates the code by him self, then you may need some kind of integration to his service.

 

Best regards
Karsten Thuen 

 
Hans Ravnsfjall
Hans Ravnsfjall
Reply

Hi Karsten

It could be a nice feature if it was possible to add some sort of ID to the email subject. So that they could seperate the mails. Some clients are complaining that they can not get the emailclient to seperate mails with same subject line. The mail client merges all the messages as a conversation.

Br.

Hans

 
Karsten Thuen Dynamicweb Employee
Karsten Thuen
Reply

Hi Hans

Ok if that is the case, then we need some more details before we can find out if it could/should be a part of Rapido. Is it the receipt email we are talking about? Or is it one of the templates that comes with Rapido that gives the trouble? 

 

Best regards
Karsten Thuen

 
Hans Ravnsfjall
Hans Ravnsfjall
Reply

Hi Karsten

Sorry, didnĀ“t realise this was a rapido specific thread

I am thinking as a general feature to have the ablitly of having a dynamicweb subject field in eg, forms module or the Item Creator

/Hans

 
Gerard Kocks
Gerard Kocks
Reply

Hello Karsten,

The proces needs to be like this:

1. Via several campains users will visit our campaign page (which is a Rapido page)
2. They fill in a form to join a game we offer them (game runs on a separate app)
3. After filling in the form we need to send the users a confirmation E-mail A.S.A.P. with that unique codes. Our customer delivers us the unique codes because those codes are generated by the app that provides the game. So we need to import the codes in Dynamic Web before the campaign starts

Is there some way to import the codes as a custom field or something and that we match a new user to that (filled in) custom field? Or do you have a better solution? Make something custom as you suggest could also be an option, but we rather use standard functionality.

Best regards
Gerard

 
Karsten Thuen Dynamicweb Employee
Karsten Thuen
Reply

Hi Gerard

You may want to read how to set up forms for editors in Dynamicweb: https://doc.dynamicweb.com/documentation-8/content/modules/forms-for-editors 

Then create a new email template, maybe a copy of "ContactEmail.cshtml". In that template you will add a line like this:


message.text.Add(MyCustomersCoolApi.GetUniqueGameCode());


So actually it depends on how to integrate with your customers api. He may have some kind of webservice that you could hook up to, and that service will then return the code.

And yes, all this is quite standard. As you are going to make a very custom feature that only this customer needs, you will have to make a little custom template that supports it perfectly. On the maintenance side you have not lost anything by creating the needed email template.

 

Best regards
Karsten Thuen

 

You must be logged in to post in the forum