VirtueMart Forum

VirtueMart 1.1.x [ Old version - no longer supported ] => Payment VM 1.1 => PayPal / PayPal Pro VM 1.1 => Topic started by: Michelle McClean on August 12, 2008, 03:00:49 AM

Title: Order still pending after payment
Post by: Michelle McClean on August 12, 2008, 03:00:49 AM
Following a purchase and successful PayPal payment the order status is not changing from Pending to Confirmed so I am having to do this manually. When I'm back at work next week I will not be able to do this!
Why is this happening? I have tried everything and double-checked all settings, etc.

VM 1.1.2
Joomla 1.5.4
Title: Re: Order still pending after payment
Post by: generator on August 17, 2008, 12:42:21 PM
Hi Michelle, I was having this issue but Harry the legend had solved this ages ago. Don't know if you still need it but want to contribute. Check out the bottom of the post - an easy 1 minute fix after all of those hours doing your head in!!!!!!!
I am using J1.5.3 (patched) and VM1.1.2

http://forum.virtuemart.net/index.php?topic=27261.0
Title: Re: Order still pending after payment
Post by: intersys on August 17, 2008, 20:22:20 PM
Hi

I've tried different solutions to this (including Harry's) but still have not been successful. The order list always shows pending after successful Paypal payments. Not sure what to try next.
Title: Re: Order still pending after payment
Post by: Michelle McClean on August 17, 2008, 20:30:12 PM
I'm also getting the dreaded 'Possible Fraud' PayPal email following some (but not all) purchases! This is all REALLY annoying. ::)
Title: Re: Order still pending after payment
Post by: Maxmmize on August 18, 2008, 10:29:39 AM
If you are using PayPal Pro then you might try my plugin which works and overcomes the pending nastiness you get. IPN works, etc.

http://myjoomlaextensions.com

Title: Re: Order still pending after payment
Post by: Michelle McClean on August 18, 2008, 13:34:25 PM
Thanks, but just using standard PayPal.
Title: Re: Order still pending after payment
Post by: cowboy1989 on October 15, 2008, 03:51:33 AM
I am a developer. i write the paypal pro module and subscriptions for http://myjoomlaextensions.com. they paid me 230$. the manager martin eric asked me write the paypal pro uk. i wrote it and sent the script to him. he promised that he would pay me the next day. but it seems he disappeared. he stole my code.
Title: Re: Order still pending after payment
Post by: efastnet on April 16, 2009, 18:19:45 PM
I too am having the same problem. Order status remains the same despite Paypal returning the status as 'confirmed'
Title: Re: Order still pending after payment
Post by: ajredding on April 24, 2009, 09:06:12 AM
To Everybody having problems:

Could you post a little more details about your installation. (ie: modifications to code, what is used for your "Paypal Extra Info" in your paypal config, etc...)

There are a few steps required to make the order change status auto-magically.. 

1) in your paypal account you need to configure the "IPN (instant payment notification)"

If you have made any modifications to your paypal extra info and it's related to order details then you will need to modify your notify.php file to accept these changes.

Title: Re: Order still pending after payment
Post by: joannah on July 28, 2009, 07:48:24 AM
Hi AJ
I saw your posts concerning setting up the configuration for paypal, i just need the product description to be sent with the paypal receipt etc that goes to the buyer and to us, as we sell tickets to events, and the people need to print the receipt as it is their ticket.

I have attached the code to my configuration, are you please able to help me as I am getting completely lost! I need to be able to hand this site over to the client so they don't have to worry and know that the buyers are getting the descriptions on the receipts.
THANK YOU!
:)
<?php
$db1 = new ps_DB();
$q = "SELECT country_2_code FROM #__vm_country WHERE country_3_code='".$user->country."' ORDER BY country_2_code ASC";
$db1->query($q);
//get the item name.
$db2 = new ps_DB();
$q1 = "SELECT order_item_name FROM #__vm_order_item WHERE order_id=".$db->f("order_id");
$db2->query($q1);
$item = $db2->f("order_item_name");


$url = "https://www.paypal.com/cgi-bin/webscr";
$tax_total = $db->f("order_tax") + $db->f("order_shipping_tax");
$discount_total = $db->f("coupon_discount") + $db->f("order_discount");
$post_variables = Array(
"cmd" => "_ext-enter",
"redirect_cmd" => "_xclick",
"upload" => "1",
"business" => PAYPAL_EMAIL,
"receiver_email" => PAYPAL_EMAIL,
"item_name" => $VM_LANG->_('PHPSHOP_ORDER_PRINT_SKU_NUMBER').": ". $db->f("order_id"),
"order_id" => $db->f("order_id"),
"invoice" => $db->f("order_number"),
"amount" => round( $db->f("order_subtotal")+$tax_total-$discount_total, 2),
"shipping" => sprintf("%.2f", $db->f("order_shipping")),
"currency_code" => $_SESSION['vendor_currency'],

"address_override" => "1",
"first_name" => $dbbt->f('first_name'),
"last_name" => $dbbt->f('last_name'),
"address1" => $dbbt->f('address_1'),
"address2" => $dbbt->f('address_2'),
"zip" => $dbbt->f('zip'),
"city" => $dbbt->f('city'),
"state" => $dbbt->f('state'),
"country" => $db1->f('country_2_code'),
"email" => $dbbt->f('user_email'),
"night_phone_b" => $dbbt->f('phone_1'),
"cpp_header_image" => $vendor_image_url,

"return" => SECUREURL ."index.php?option=com_virtuemart&page=checkout.result&order_id=".$db->f("order_id"),
"notify_url" => SECUREURL ."administrator/components/com_virtuemart/notify.php",
"cancel_return" => SECUREURL ."index.php",
"undefined_quantity" => "0",

"test_ipn" => PAYPAL_DEBUG,
"pal" => "NRUBJXESJTY24",
"no_shipping" => "1",
"no_note" => "1"
);
if( $page == "checkout.thankyou" ) {
$query_string = "?";
foreach( $post_variables as $name => $value ) {
$query_string .= $name. "=" . urlencode($value) ."&";
}
vmRedirect( $url . $query_string );
} else {
echo '<form action="'.$url.'" method="post" target="_blank">';
echo '<input type="image" name="submit" src="https://www.paypal.com/en_US/i/btn/x-click-but6.gif" alt="Click to pay with PayPal - it is fast, free and secure!" />';

foreach( $post_variables as $name => $value ) {
echo '<input type="hidden" name="'.$name.'" value="'.htmlspecialchars($value).'" />';
}
echo '</form>';

}
?>