E-Junkie Forum http://www.e-junkie.com/bb/ E-Junkie Forum RSS en-us Copyright 2013, 19.5 Degrees. All rights reserved. webmaster@e-junkie.com webmaster@e-junkie.com Tue, 1 Dec 2009 19:31:42 GMT Sat, 25 May 2013 16:02:02 GMT 681 E-JUNKIE 5 E-Junkie Forum http://www.e-junkie.com/bb/ http://www.e-junkie.com/ej/logo.gif 290 104 Post #8 http://www.e-junkie.com/bb/topic/3824/pg/0#post12406 http://www.e-junkie.com/bb/topic/3824/pg/0#post12406 Tue, 1 Dec 2009 19:31:42 GMT http://www.e-junkie.com/ej/help.keygen.htm

...that the post value isn't 'os0' but 'option_selection1_X'. I can thus create my code. Hooray!]]>
E-junkie Discussions; ShiftyGeezer
Post #7 http://www.e-junkie.com/bb/topic/3824/pg/0#post12406 http://www.e-junkie.com/bb/topic/3824/pg/0#post12406 Sun, 29 Nov 2009 21:48:10 GMT
I've simplified for password creation code to help track the problem of it not returning a code. I've just tried returning the 'os0' variable, with this .php code...

if ($_POST['handshake']!==md5("email@address.com".md5("********"))){
echo ('handshake failed');
exit;
}else{
// Return registration code
$a='os0 '.$_POST['os0'];
echo ($a);
}

After a transaction, the response email includes [%os0%] and [%codes%]. [%os0%] returns my cariation value. [%codes%] prints "os0 " with no actual property value, so it seems like my .php script isn't receiving it.

What is preventing my .php receiving the correct POSTed value?]]>
E-junkie Discussions; ShiftyGeezer
Post #6 http://www.e-junkie.com/bb/topic/3824/pg/0#post12406 http://www.e-junkie.com/bb/topic/3824/pg/0#post12406 Thu, 19 Nov 2009 00:47:04 GMT $_POST['os0']

Regarding thank-you page/email template tokens, note how our documentation makes distinctions as to which tokens are supported where.

The [%gross%] token is not supported in the Message (HTML) field for individual products; it only works in thank-you emails and in the Common Thank-you Page HTML field (in Admin > Account Prefs). Anything in your Common Thank-you Page HTML field gets inserted at the bottom of the thank-you page, after product-specific information. You may find this sample thank-you page helpful to see where things go:
https://www.e-junkie.com/ecom/rp.php?t=jg-kqswfja3e6cfcfd&c=fup

You have only one Option configured for this product using Variations, so you would only have [%on0%] (think of this as "Option Name 0") and its corresponding user-submitted [%os0%] ("Option Specified 0"). There is no on1/os1, etc. as you are not using a 2nd or 3rd option for the product.

The [%codes%] token is null because your keygen URL is not outputting any string to insert for that value.]]>
E-junkie Discussions; E-junkieGuru
Post #5 http://www.e-junkie.com/bb/topic/3824/pg/0#post12406 http://www.e-junkie.com/bb/topic/3824/pg/0#post12406 Mon, 16 Nov 2009 22:19:18 GMT
In my .php code, I use :

$s = encrypt($_POST['usercode']);
echo ($s);

...where encrypt() is a local function. I'm not sure where I got the variable 'usercode' from though! My product variation is called 'PZAMM User Code.' How should I access this in the .php code generator?

The template HTML/email is set to use template, but is continuing to print the codes and not the actual values. [%first_name%] works, but [%gross%] is printed as the token, while [%on1%] and [%codes%] are blank.

I expect the code faults are because my returned code is a blank as a result of reading a null string because I'm not referencing the correct POSTed variable.]]>
E-junkie Discussions; ShiftyGeezer
Post #4 http://www.e-junkie.com/bb/topic/3824/pg/0#post12406 http://www.e-junkie.com/bb/topic/3824/pg/0#post12406 Tue, 3 Nov 2009 13:31:49 GMT
Can you please check if you have checked the "Enabled templated email" checkbox in your product's settings?]]>
E-junkie Discussions; E-junkieChef
Post #3 http://www.e-junkie.com/bb/topic/3824/pg/0#post12406 http://www.e-junkie.com/bb/topic/3824/pg/0#post12406 Mon, 2 Nov 2009 21:05:17 GMT
I have one little question remaining. In the "Custom Thankyou" message I tried to embed the purchase details of user code and registration code using this "Optional Email Message" of the product details page :

---
Extra thankyou message.
Thank you for buying this lovely thing.

Your computer key is : [%o1%]
Your registration code is: [%codes%]
---


The email contains the code tags and not the actual user and registration codes. Is there a way to include these data?]]>
E-junkie Discussions; ShiftyGeezer
Post #2 http://www.e-junkie.com/bb/topic/3824/pg/0#post12406 http://www.e-junkie.com/bb/topic/3824/pg/0#post12406 Sun, 1 Nov 2009 18:08:37 GMT
Regsitration code will be emailed to the buyer and you can also customize the thankyou page to show the code there.]]>
E-junkie Discussions; E-junkieChef
Post #1 http://www.e-junkie.com/bb/topic/3824/pg/0#post12406 http://www.e-junkie.com/bb/topic/3824/pg/0#post12406 Sun, 1 Nov 2009 16:51:15 GMT
To fend of freeloaders, I need to make sure people can't just type in the .php URL and enter their local machine code free of charge! Thus my current plan is to have the registration script check a Post variable to determine if the access is from a legitimate purchase or not.

This is where I get confused with eJunkie's options. http://www.e-junkie.com/ej/help.keygen.htm is about generating a custom code, but doesn't forward the user to a custom webpage where they can put in their local computer code. http://www.e-junkie.com/ej/help.redirection.htm sounds about right, where I would direct the users to a custom page. My concern here is using the GET method, the URL could be used by other people. Is there a hidden POST method I could test instead? I can't really limit each user to one registration code through a database lookup as buyers may want several copies for several machines. Then there's Send Transaction Data to a URL (http://www.e-junkie.com/ej/help.integration.htm) which also sound right, uses POST, but seems to be geared towards payment gateways, and so wouldn't operate in response to a PayPal purchase but would instead go from the buyer clicking the Pay button to my .php script without the whole payment thing.

Would you be able to advise me on the correct way to integrate my scheme? In simple terms, the steps are...

1 Customer downloads software
2 Customer runs software
3 Software generates Local Machine Code (LMC)
4 Software enables purchase button
5 Customer clicks purchase button
6 Website opens on eJunkie cart with software added (Buy Now button equivalent)
7 Buyer pays
8 Transaction complete
9 Buyer directed to custom .php page that only opens on successful purchase through eJunkie. Enters LMC and gets script generates Registration code
10 Customer enters code and software is unlocked for their LMC.

It's step 8 to 9 that I'm having trouble with. And sorry for the epic post! Hope that isn't too much information!]]>
E-junkie Discussions; ShiftyGeezer