Tuesday, October 31, 2006

Complex Stay-in-touch

Salesforce includes a stay-in-touch form but changing this can be time consuming. Several of our customers are now using Clicktools to manage complex stay-in-touch requests. Simply, this takes information in Salesforce about a Contact, sends it to the contact and enables them to update it. This new information is imported back in to Salesforce.

There are a couple of important factors to consider when designing this sort of form.

1) Use manual synchronization. If you use automatic synchronization you risk good information being overwritten with bad. Using a manual synch enables you to exploit the "triage" to quickly scan and correct and errors before they are imported.

2) Address lines must be in one text field. When transferring information out of Salesforce in to the form, you can choose between individual address lines (1-3) or the complete address. BUT, you can only put information back in to Salesforce in one address line, not 3. So, to correctly place information back in to the address field you MUST put the address line in to one text field or one option in a multi-text field (the recommended approach).

The example URL below populates the first 6 questions in a surveythat would be used in a Clicktools template to pass across individual details is:

"surveyURL&q1=${Contact ID}&q2=!urlencode{${First Name}}%20!urlencode{${Last Name}}%20!urlencode{${Preferred Name}}%20!urlencode{${Title}}%20!urlencode{${Organisation}}%20!urlencode{${Email}}%20!urlencode{${Phone}}%20!urlencode{${Fax}}&q3=!urlencode{${Mailing Address Line1}%20${Mailing Address Line2}%20${Mailing Address Line3}}%20!urlencode{${Mailing City}}%20!urlencode{${Mailing State/Province}}%20!urlencode{${Mailing Zip/Postal Code}}&q4=!urlencode{${Mailing Country}}&q6=${Primary Contact}"

If you prefer to use Mailing Address, you can do. In this case, the URL looks like this:

"surveyURL&q1=${Contact ID}&q2=!urlencode{${First Name}}%20!urlencode{${Last Name}}%20!urlencode{${Preferred Name}}%20!urlencode{${Title}}%20!urlencode{${Organisation}}%20!urlencode{${Email}}%20!urlencode{${Phone}}%20!urlencode{${Fax}}&q3=!urlencode{${Mailing Address}}%20!urlencode{${Mailing City}}%20!urlencode{${Mailing State/Province}}%20!urlencode{${Mailing Zip/Postal Code}}&q4=!urlencode{${Mailing Country}}&q6=${Primary Contact}"

Please note the use of:

  • 'urlencode' to cater for spaces and other characters that could cause trouble on a URL
  • '' to concatenate multiple salesforce fields in to a clicktools 'multi-' question
  • %20 to enter a space which stops field being placed in the wrong question(useful if you have blank address fields)

I hope you gives you some help in building stay in touch requests using clicktools. As ever, if you have any questions, please contact us.

No comments: