Author |
Topic  |
leatherlips
Senior Member
   
USA
1838 Posts |
|
leatherlips
Senior Member
   
USA
1838 Posts |
|
Carefree
Advanced Member
    
Philippines
4222 Posts |
Posted - 06 July 2008 : 14:06:26
|
What would be needed, Leather is for the computer to generate a random string, store it against their opt-in info & send it to the user like this:
Then the target.asp page would compare it to the value in the DBase like this:
< |
Edited by - Carefree on 06 July 2008 14:10:11 |
 |
|
Carefree
Advanced Member
    
Philippines
4222 Posts |
Posted - 06 July 2008 : 14:38:27
|
You could use something like this to create your random string:
That way, your variable string will always be 64 characters, regardless of the length of "MEMBER_ID". Since the code will have to match a stored variable to confirm opting in, it should preclude any malicious people opting someone else in.
However, if you allow non-forum members to sign up, you'll have to use a different pattern recognition to do the job. Use their Email address in an approach like this:
The link sent would have to include some form of their email address, possibly encrypted.
You could do this:
EncEM=sha256(" & email & ")
Store EncEM as ENCRYPTEDEMAIL Store VariableString as WHATEVERVALUE
Making the link like this:
Then your opt-in table would have to include at least three fields (email address, encrypted email, whatevervalue).
< |
 |
|
Carefree
Advanced Member
    
Philippines
4222 Posts |
Posted - 06 July 2008 : 15:30:02
|
Here Leather, an all-in-one for you
< |
Edited by - Carefree on 06 July 2008 15:34:19 |
 |
|
leatherlips
Senior Member
   
USA
1838 Posts |
|
leatherlips
Senior Member
   
USA
1838 Posts |
|
Carefree
Advanced Member
    
Philippines
4222 Posts |
Posted - 06 July 2008 : 17:08:27
|
You'll have to create a table (if one doesn't already exist with that mod) to hold those values, yes.
You can do it with a dbs file like this:
Leave the blank line in. Save in your root forum directory as "dbs_optin.asp". Then install it like normal from Admin Home.
The file above doesn't replace any existing files & you'll have to finalize whatever steps are necessary to add the person to your list of recipients. There's a comment delineated section in the file for that (list and it should be obvious).
If you have trouble with it, let me know & I'll DL that mod and finish it for you.< |
Edited by - Carefree on 06 July 2008 17:09:01 |
 |
|
Carefree
Advanced Member
    
Philippines
4222 Posts |
Posted - 06 July 2008 : 17:12:20
|
To use that file that I created, you'll need to set the value of a variable "Generate" to 1 from the form where they elect to receive the newsletter, then change the action to target.asp?=(email).< |
 |
|
Carefree
Advanced Member
    
Philippines
4222 Posts |
Posted - 06 July 2008 : 17:25:56
|
OK - downloaded it.
In mailinglist.asp, line 45, change it to say:
That'll get it started.
I added in the final steps from mailinglist.asp into target.asp
< |
Edited by - Carefree on 06 July 2008 17:56:27 |
 |
|
Carefree
Advanced Member
    
Philippines
4222 Posts |
Posted - 06 July 2008 : 18:15:49
|
I have a bug to solve, then I think it's done.
I'm getting an Object required: 'my_Conn' error referring to these few lines:
Here's the strSql output to Response.Write
quote:
INSERT INTO OPTIN (EMAIL, ENCRYPTEDEM, WHATEVER) VALUES ('example@msn.com', 'b1b651a4b3876253d6174b0bc2219d53ae89d0b20f864532f356bb5f66128ec7', '6b86b273ff34fce19d6b804eff5a3f5747ada4eaa22f1d49c01e52ddb7875b4b');
It's giving me what I expect it to, anybody see why I'd be getting the error?
Edit - never mind, I'm an idiot. I forgot to include config.asp< |
Edited by - Carefree on 06 July 2008 18:26:09 |
 |
|
Carefree
Advanced Member
    
Philippines
4222 Posts |
Posted - 06 July 2008 : 20:42:26
|
Done. It all works.
< |
 |
|
Carefree
Advanced Member
    
Philippines
4222 Posts |
Posted - 06 July 2008 : 21:02:04
|
My part works lol. I created a test newsletter, it says it sent it (to the right members from the database), but it didn't really get sent. Further, it deletes everything you typed as soon as you confirm the send, so if you want to continue testing, I'd back it up.< |
 |
|
Carefree
Advanced Member
    
Philippines
4222 Posts |
Posted - 06 July 2008 : 21:49:58
|
Here's the routine from the nlEmail_list.asp (newsletter sending):
It pulls the correct email address from the database, claims it sends it ok - but nothing apparently is sent. I don't see anything wrong with it but I may have been looking too long today.< |
 |
|
leatherlips
Senior Member
   
USA
1838 Posts |
|
Carefree
Advanced Member
    
Philippines
4222 Posts |
Posted - 06 July 2008 : 22:39:46
|
Leather, the problem isn't with the double-opt in. That part works perfectly. The problem is that the newsletter isn't being sent at all (if you try html version).< |
 |
|
Topic  |
|
|
|