Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Capturing email address..

Status
Not open for further replies.

ahksar

Programmer
Jan 11, 2001
43
US
Hi,
I am sending subscribers an email about a survey they have to fill, and I have given the link to the survey in the email. When they click on the link, is there a way that I can capture their email address, and pass it on to the form, so that I can keep track of who filled out the form through their email ID's?I guess I have to use CGI variables, but I dont know which one.
Any help will be greatly appreciated.Thanks
ahksar
 
Hi ahksar

First thing that comes to mind is to code there Email address into a URL variable in the link you send them.

so there link would look like
<a href=&quot;takeasurvey.cfm?myemailaddress=whereitwassent@who.com&quot;>
Click me to take a survey</a>

You get the idea.

Then when they arrive at the survey you can read the URL variable called URL.myEmailaddress and set a hidden form variable with it.

Let me know if you need more detail, or if this works for you.

 
Hey Ahksar,

I would add a few suggestions on top of what tlhawkins posted. Instead of passing the e-mail address (make sure to use #urlencodedformat()#) in plain text, you might want to encode it with encrypt() so the user doesn't think they're passing their e-mail address to something. People are very privacy minded and may not like seeing their address in a link that they're about to click on. Another option would be to pass the primary key for the database record that holds their e-mail address. This way you just pass back a number and then retrieve their e-mail address from the database. This assumes that you're using a table to send out your e-mails though.

Good luck,
GJ
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top