The Community is hosting an End of Summer sweepstakes! Participants must complete tasks to earn tickets that will enter them with a chance to win a free year of Constant Contact and other great prizes!*
*No Purchase Necessary. For Official Rules, visit here. Constant Contact’s End of Summer 2020 Sweepstakes ends on October, 20, 2020 at 11:50 PM EST.

Problem in replacing the contact custom field information in a link

Highlighted
Occasional Participant

Problem in replacing the contact custom field information in a link

Hi,


I have a link in my email which contains a unique key in its querystring. i have to replace that unique value with the contact custom field info. When i tried to replace that iam having problem . Here is the way iam doing


<a href="http://xyz.com/UI/emails/mypage.aspx?hashkey=$SUBSCRIBER.CUSTOMTEXT2$">

                <img src="http://xyz.com/UI/Includes/Images/myacc.gif" alt="Account info" border="0" /></a>


In free text iam able to replace the properties with out any problem. I have problem in replacing the properties in the link. The above property is not replaced(http://www.xyz.com/UI/emails/mypage.aspx?hashkey=$SUBSCRIBER.CUSTOMTEXT2$ . I tried also by using property tag in the above link but it is saying not in proper format.


Is it possible to replace these things in a link. If its possible please let me know how to do that.


Thanks,


Vijay


 

8 REPLIES 8
Highlighted
Employee

Dynamic Links

If you are using a new wizard email, you can insert your contact details into your email by making the link something like http://www.mywebsite.com?email=$subscriber.email$. Please note that you would need to disable link tracking for this to work. Please take a look at this FAQ for more details regarding dynamic links in new wizard.


 


If you are using a custom XHTML email, the process is a little different. You would need to store the HTML for the link into a few custom fields, and then insert those details directly into your html using the format: <Property name="Subscriber.CustomText1"/>


 


This post goes into more detail on creating dynamic links in an XHTML email. However, to summerize the portion that is relevent for you:


 


If you wanted to create a link that went to http://www.yourwebsite.com/ID=(USER ID NUMBER) where the (USER ID NUMBER) would be dynamically generated based on who is reading it, your custom fields would look as follows:

 

Custom Field 1 would be the same for every contact:

 

<a href=”http://www.yourwebsite.com/ID=

 

Custom Field 2 would be each contact’s individual id number:

 

4155

 

Custom Field 3 would be the same for every contact:

 

“>Click Here</a>


 


I hope this helps to clear things up. Please let us know if you have any questions regarding this. Thanks.

David J

Highlighted
Occasional Participant

Does these dynamic links are trackable ?

Hi David,


Thanks for the reply.


Its working now.  I have one query. Does these dynamic links are trackable by the api or not?


 


Thanks,


Vijay


 


 

Highlighted
Employee

Dynamic Link Track

Since every dynamic link is unique depending on which user is looking at it, and the maximum number of unique visits any link would have would be 1, we do not track dynamic links. Dynamic links are not be available for tracking through both the API as well as reports on our website. I apologize for any inconvenience that this causes. Please let us know if you have any other questions.

David J

Highlighted
Occasional Participant

But we should know whether

But we should know whether the link got atleast that one visit.


Anyway thanks for the reply


one more issue is, custom field accepting only 50 characters, is there any way to increase that length other than splitting my url into multiple fields as my url is of larger size


 


Thanks,


Vijay

Highlighted
Employee

Character Length

The maximum field length for custom fields is 50 characters, as you had pointeed out. Unfortunately we do not have any way to increase the maximum size of these fields, and if your URL does not fit inside that character limit, you would need to split your URL into multiple fields. For a list of the maximum character lengths for all fields, I would recommend taking a look at the bottom of the Contacts Collection reference page.

David J

Highlighted
New Member

bit.ly api

I'm running into the same issue (length of custom fields limiting my URL length, thus making it impossible to use.)  I'm planning to use the bit.ly class to shorten each url within vb.net.  Don't know your circumstances, but thought I would pass along in case helpful.


I found this posting that creates a class in vb.net or c#:


http://www.dreamincode.net/forums/index.php?app=blog&module=display&section=blog&blogid=114&showentr...


Good luck.

Mark Evans


Director of Marketing


Above the Treeline


 

Highlighted
New Member

Text to Display - not sticking

I've been able to add a variable to a link, like this:


http://www.example.com/?id=$subscriber.customtext1$


Using the normal web GUI, I'm setting both the "Text to Display" and "Link" to this value, and disabling link tracking.  So far so good.


Either when I preview the email, or after I send the email and then make a copy of it, the "Text to Display" changes to:


http://www.example.com/?id=Custom Field 1


The "Link" value stays the same, which is good.  But it's not good (nor correct behavior) that the "Text to Display" keeps changing.  When the Text to Display is "Custom Field 1" (rather than $subscriber.customtext1$), and I send the email, it actually displays "Custom Field 1" in the email.

Highlighted
Employee

Re: Text to Display - not sticking

Hi Ben,


 


Thank you for letting us know about this. I am going to do some research on this and submit this to our engineering department to look at. I do want to let you know that the best way to submit something you thing is not working correctly would be through support. As I said though I will certainly look into this and report my findings to engineering.


 


I apologize for any inconvenience that this issue has caused. Thank you for letting us know.

David J

Developer Portal

View API documentation, code samples, get your API key.

Visit Page

Constant Contact 2020 End of Summer Community Sweepstakes!

The Constant Contact User Community is hosting a sweepstakes. The more you participate, the more chances you have to win! Read on to learn more...

Read More
Featured