Author Topic: From Check Out Cannot Confirm w/ PP  (Read 2889 times)

ajvobara

  • Beginner
  • *
  • Posts: 4
From Check Out Cannot Confirm w/ PP
« on: April 27, 2009, 03:43:31 am »
I've been searching the post like crazy and found others with similar sounding problems but not described exactly the same..  So, sorry if I missed something.. but, I've tried all the fixes for those post and nothing has worked..

This is an iexplorer issue for sure since this doesn't happen with firefox..  every time I try to confirm the order FROM THE CHECK OUT section the paypal site gives up and redirects to here..  https://www.paypal.com/us/cgi-bin/webscr?cmd=_flow&SESSION=3u-HAJKCIAIlpUG6GVhIpQ4o3QQozLmFVY1Z-jvx5sXBxsmyM_EH8aqI0cm&dispatch=5885d80a13c0db1f998ca054efbdf2c25fe4a05bcb33bff6aad6e850552f81af
BUT, if you go back to the Account Maintenance page for the user and find the order there, the Pay w/ Paypal button sends you to the correct page for payment???  How is this possible that it only happens in the check out and not in Account Maintenance?

Is there a fix for this since 90% of the site vistiors are going be using IE??

thanx and I look forward to all your ideas..

ajvobara

  • Beginner
  • *
  • Posts: 4
Re: From Check Out Cannot Confirm w/ PP
« Reply #1 on: April 27, 2009, 03:55:51 am »
Ok..  forget this post since I just used the advice from this topic http://forum.virtuemart.net/index.php?topic=39584.0 and did replace the code as suggested..  now the confirm button redirect to the Pay w/ Paypal button that work fine..

thanx a million Soeren !!!!
 
I made this change..


Code:
if( $page == "checkout.thankyou" ) {to

Code:
if( false ) {

apollo9k

  • Beginner
  • *
  • Posts: 7
Re: From Check Out Cannot Confirm w/ PP
« Reply #2 on: September 14, 2009, 20:08:33 pm »
I changed the code and still no luck.

Code: [Select]
<?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);

$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_PO_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_total2),
"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( 
false ) {
$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" border="0" 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>';

}
?>

It seems no matter what I try. The Confirm Order button never takes the shopper to PayPal anymore. Funny thing is it used to, but now it doesn't