Jump to content

[RESOLU] Download notice addition


Recommended Posts

Hi,

I would like to trigger a URL when the virtual product download email is sent to the customer.
Once the email is triggered, i want a loop that would take each product reference# and member email to be posted to a specific adress.

for example, the script for the email contains these varaibles :

$product_reference_number1 = [1] ;
$product_reference_number2 = [2] ;
$curstomer_email = [[email protected]] ;

So when the loop executes, i would get these URL posted/triggered:

http://www.mydomain.com/folded/process.php?item=1&[email protected] 
http://www.mydomain.com/folded/process.php?item=2&[email protected] 




Basically, these URL trigger another script!
How could i do it

I tried the following inside OrderHistory.php after line 151 without results.

 $URL="www.mydomain/folder/process.php";
               $email = "[email protected]";
               $item = "1";
               $URL_tail = "?item=".$item."&smail;=".$email ; 
               $ch = curl_init();    
               curl_setopt($ch, CURLOPT_URL,"http://$URL");  
               curl_setopt($ch, CURLOPT_POST, 1); 
               curl_setopt($ch, CURLOPT_POSTFIELDS, $URL_tail);curl_exec ($ch);     
               curl_close ($ch); 
               // End token   



Above should post this url invisibly:

www.mydomain/folder/process.php?item=1&[email protected]

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...