Email confirmation sent after Paypal payment has been completed + itemized the product
Problem: Email confirmation sent after Paypal payment has been completed + itemized the product
The problem above was requested of my Canadian clients for their site . I used the virtuemart patch here but it took me a long time to figure out and i encountered a lot of errors. What I did was I reverted all files in orginal virtuemart 1.1.4 and started creating my own hack.
Requirement:
Works in latest joomla 1.5.x and virtuemart 1.1.x
Here’s how i solved my problem.
1. Purchase the product by clicking here. Follow this link on how to use : http://www.virtuosomaster.com/tutorials/vm-paypal-integration-pro-in-virtuemart/
2. Back up you administrator/components/com_virtuemart
3. Modify your class/ps_checkout.php .
Look for :
$this->email_receipt($order_id);
and comment it :
//$this->email_receipt($order_id);
4. Modify html/checkout.result.php .
and look for this line of code:
if ($db->next_record()) {
$order_status = $db->f(“order_status”);
if($order_status == PAYPAL_VERIFIED_STATUS
|| $order_status == PAYPAL_PENDING_STATUS) {
and insert the code below after it:
if($_SESSION[emailed]==1){
require_once(CLASSPATH.’ps_checkout.php’);
$ps_checkout = new ps_checkout;
$ps_checkout->email_receipt($order_id);
$_SESSION[emailed]=0;
}
5. Save and test your work.
6. Need assistance just pm me in skype: arni.cinco
7. Donate if you find my tutorial helpful. Thanks



















