Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

PayPal WPP Direct Payments & Express Checkout Support


dynamoeffects

Recommended Posts

:blink:

 

Hi Brian,

 

Great functionalities on the new version. I like the option to send email when cc declined. That will help us most certainly.

 

I can't seem to get the new version working though, the old one neither when i reinstalled it.

 

To give some history, I had stopped using WPP until it suited more our scenario. So have been using the plain and simple built in cc payment module.

 

I remember installing a new set of country codes, but not sure which version. It seems to have screwed up my tables, so that previous customers now have odd named states within the US.

Is this interfering with WPP even though I made sure the address shows NM, US?

 

Even the old version 0.5 isn't working anymore? Also the email feature whereby the store owner email receives information if cc declined, doesn't seem to be working?

 

To be honest I just took the paypal_wpp.php file and copied it over the old one. Looking at the update changes, that was all that was mentioned, but now I am wondering.

Transaction ID:

Payment Type: PayPal Direct Payment

Payment Status: Completed

AVS Code: Error

CVV2 Code: Error

Orders get processed with V0.6 but funds never captured (authorized in my case). Haven't been receiving dump files either (is the destination email same as store owner email address?).

when I reinstalled V0.5 transaction systematically turned down, error 10752 or something to that effect. Is this to do with state name being incorrect?

Link to comment
Share on other sites

I remember installing a new set of country codes, but not sure which version. It seems to have screwed up my tables, so that previous customers now have odd named states within the US.

Is this interfering with WPP even though I made sure the address shows NM, US?

I had the same problem when I installed World Zones. It deletes all the old zones. The problem is that customer records don't hold the state name; just a pointer into the zone table. World Zones creates new numbers, so the customer records are pointing to the wrong names. The only fix I am aware of requires that you go into the customer table and fix the pointers. It's a huge pain.

 

Even the old version 0.5 isn't working anymore?

There is no reason that it shouldn't work. Make sure that you are pointing to the Pear files and your certificates correctly. Uninstall/reinstall resets defaults.

 

To be honest I just took the paypal_wpp.php file and copied it over the old one. Looking at the update changes, that was all that was mentioned, but now I am wondering.

You need to uninstall the old one, copy the file over, then reinstall. This adds the names of new fields on the configuration page.

 

Orders get processed with V0.6 but funds never captured (authorized in my case). Haven't been receiving dump files either (is the destination email same as store owner email address?).

when I reinstalled V0.5 transaction systematically turned down, error 10752 or something to that effect. Is this to do with state name being incorrect?

 

The treatment of error transactions as successful is an 0.6 bug. I have provided Brian with a fix, which should make it into the version that he has promised in the next day or two.

Link to comment
Share on other sites

hello,

I am newb. Using this module will my customers be able to charge their credit card without signing up for paypal? do i require to sign up for the paid service in paypal to use this? How do install this? Will this automatically put my customers back on my website at the end of transaction? And will they receive an email with this module?

-tunata

Link to comment
Share on other sites

RE: v0.5 - PayPal Direct Payments & Express Checkout v0.5

 

OK, I've run into a problem... checkout went fine first through the site

itself, then also going through the express payment. But now when I try

to make additional purchases on this account I don't get the option to

pay directly through the website any longer... All I get on the page is

the coupon box & the comments box... no payment options.

Link to comment
Share on other sites

Why is the Express Checkout button displayed on the Payment page if the Customer is directed back to the Shipping back when they return from Express Checkout? Shouldn't the Express Checkout button be displayed on the Shopping Cart BEFORE the shipping page?

Link to comment
Share on other sites

On checkout_payment.php, I chose Express Payment, logged in to Paypal, returned to the shopping cart, clicked Continue, I was directed to checkout_confirmation.php, but the Payment Method says "Paypal Direct" instead of "Paypal Express".

 

 

On checkout_confirmation.php, I clicked the "Edit" link next to the Payment Method, I was directed to checkout_payment.php but I didn't see any payment options to choose from. I expected to see text fields to enter credit card information for Direct Payment and a Paypal Express button.

Link to comment
Share on other sites

hello,

I am newb. Using this module will my customers be able to charge their credit card without signing up for paypal? do i require to sign up for the paid service in paypal to use this? How do install this? Will this automatically put my customers back on my website at the end of transaction? And will they receive an email with this module?

-tunata

 

Your customer can use their credit card without being redirected to PayPal, and they don't really need to have a PayPal account if they want to pay with credit card.

You must apply for a Web Payment Pro with paypal which they will charge you $20.00/month.

Installation guide is included in the package when you download it. If you need assistance to install this module, send me a PM.

Your customer will be redirected to your website if they choose to pay with paypal account, but if they choose to pay with credit card, they don't even leave your site.

Yes, your customer receive an email after the transaction completes., however this is not something related to this module. Sending confirmation email is related to your website configuration.

Good luck

Regards,

Link to comment
Share on other sites

Your customer can use their credit card without being redirected to PayPal, and they don't really need to have a PayPal account if they want to pay with credit card.

You must apply for a Web Payment Pro with paypal which they will charge you $20.00/month.

Installation guide is included in the package when you download it. If you need assistance to install this module, send me a PM.

Your customer will be redirected to your website if they choose to pay with paypal account, but if they choose to pay with credit card, they don't even leave your site.

Yes, your customer receive an email after the transaction completes., however this is not something related to this module. Sending confirmation email is related to your website configuration.

Good luck

 

You can get by with standard with no monthly charge I believe. You just cant take in fax or call in orders that will require the Pro that costs 20 USD a month

Link to comment
Share on other sites

You can get by with standard with no monthly charge I believe. You just cant take in fax or call in orders that will require the Pro that costs 20 USD a month

With Standard, you can't use this module. If you use standard, that is the usual PayPal module which your customers will be redirected to PayPal website. This is the link to more details about the standard.

You must have a Pro in order to charge your customers credit card directly without redirecting to PayPal web site (what actually this contribution is based on). For more information about the Pro please Click here.

 

If you want to see a live and working version of this contribution (module) you can visit our website by clicking HERE.

Regards,

Link to comment
Share on other sites

But now when I try

to make additional purchases on this account I don't get the option to

pay directly through the website any longer... All I get on the page is

the coupon box & the comments box... no payment options.

 

Instead of blanking out that area, I'll be adding a checkbox that will give the user the option of choosing another checkout method that will clear the EC variables. Unfortunately, it will have to restart the checkout process.

 

 

Why is the Express Checkout button displayed on the Payment page if the Customer is directed back to the Shipping back when they return from Express Checkout? Shouldn't the Express Checkout button be displayed on the Shopping Cart BEFORE the shipping page?

 

If you installed everything correctly, a button is displayed at the top of the shipping page. The reason they are sent back to the shipping page is because when they go to PayPal, they have the option of choosing a different shipping address. To avoid charging them the wrong amount for shipping, they are returned to the first page to recalculate all of the subtotals.

 

I believe SteveDallas mentioned that there's a way around this, but I'd need to take a look at my notes to remember what it was (Sorry, Glen). I could have it compare addresses so that if the zipcode is the same, send them to the confirmation page instead.

 

 

On checkout_payment.php, I chose Express Payment, logged in to Paypal, returned to the shopping cart, clicked Continue, I was directed to checkout_confirmation.php, but the Payment Method says "Paypal Direct" instead of "Paypal Express".

On checkout_confirmation.php, I clicked the "Edit" link next to the Payment Method, I was directed to checkout_payment.php but I didn't see any payment options to choose from. I expected to see text fields to enter credit card information for Direct Payment and a Paypal Express button.

 

"PayPal Direct" is the name of the whole module. Still, if I remember correctly, it should still say "Express Checkout." I'll take a look at it. There are still some bugs abound, no doubt.

Please use the forums for support! I am happy to help you here, but I am unable to offer free technical support over instant messenger or e-mail.

Link to comment
Share on other sites

Version 0.7 is out

 

 

Thanks to some great bug hunting by Glen (SteveDallas), this version seems pretty solid. There's still a lot of work to do on the other parts of the catalog, but this will get the job done. Again, the only difference is the actual module: includes/modules/payment/paypal_wpp.php Read the readme if you're not sure how to properly uninstall and reinstall a module!

 

Changelog:

*Transaction search has been thoroughly tested so, God willing, the payment without order problem should be fixed

*Error dumps that get emailed to the store admin are even more detailed. How exciting.

*If you have it setup in your PayPal account, Express Checkout will now return the customer's telephone number (Thanks to Glen aka Steve Dallas)

*PayPal will sometimes return more than one error message. Now they're ALL displayed to the customer

*Shipping address is now sent to PayPal (Thanks to WillBrand)

*I stripped out a lot of the contributed code because it was unnecessary and caused more problems than it solved. (I appreciate it, though)

*International support has been improved (Thanks to Glen aka SteveDallas)

*Debugging variable bug fixed (heh)

*You can now override the shipping address sent back from PayPal (for Stew's gift address support thingy) but it's not working right just yet. What a cruel game I play.

 

I've invested all the time in this today that I can. I have too many other ongoing projects that I must tend to. Hope this fixes some of the more common issues.

Please use the forums for support! I am happy to help you here, but I am unable to offer free technical support over instant messenger or e-mail.

Link to comment
Share on other sites

Version 0.7 is out

Thanks to some great bug hunting by Glen (SteveDallas), this version seems pretty solid. There's still a lot of work to do on the other parts of the catalog, but this will get the job done. Again, the only difference is the actual module: includes/modules/payment/paypal_wpp.php Read the readme if you're not sure how to properly uninstall and reinstall a module!

 

Congradulations with your great work. :thumbsup:

I have installed the 0.7 and everything is working just fine. I think you can take a break for few days now. :thumbsup:

THANK YOU!

Regards,

Link to comment
Share on other sites

Version 0.7 is out

Thanks to some great bug hunting by Glen (SteveDallas), this version seems pretty solid. There's still a lot of work to do on the other parts of the catalog, but this will get the job done. Again, the only difference is the actual module: includes/modules/payment/paypal_wpp.php Read the readme if you're not sure how to properly uninstall and reinstall a module!

 

Thanks, Brian. I installed it and made a couple of test transactions. Everything looks solid.

 

One more bug... in README.html, you missed a line break in the changelog for 0.6b before the last change.

 

--Glen

Edited by SteveDallas
Link to comment
Share on other sites

One more bug... in README.html, you missed a line break in the changelog for 0.6b before the last change.

 

I take back anything nice I ever said about you!

Please use the forums for support! I am happy to help you here, but I am unable to offer free technical support over instant messenger or e-mail.

Link to comment
Share on other sites

*You can now override the shipping address sent back from PayPal (for Stew's gift address support thingy) but it's not working right just yet. What a cruel game I play.

 

You mean you're just toying with me?????

Do, or do not. There is no try.

 

Order Editor 5.0.6 "Ultra Violet" is now available!

For support or to post comments, suggestions, etc, please visit the Order Editor support thread.

Link to comment
Share on other sites

Why are the modifications written so that once a user is in the EC flow, any attempt to change the shipping address redirects them to ec_process?

 

It seems to me, IMHO, that once they've authorized the charge to their PayPal account, they should be able to modify the address information provided at checkout without going back to PayPal.

 

Wouldn't allowing the user to modify the shipping address via osC effectively override the shipping address sent from PayPal?

Do, or do not. There is no try.

 

Order Editor 5.0.6 "Ultra Violet" is now available!

For support or to post comments, suggestions, etc, please visit the Order Editor support thread.

Link to comment
Share on other sites

Brian-

 

The way you've written this, should a temporary account be deleted upon reaching checkout_success.php, or only when the user clicks on the continue button on that page?

 

Cheers

Stew

Do, or do not. There is no try.

 

Order Editor 5.0.6 "Ultra Violet" is now available!

For support or to post comments, suggestions, etc, please visit the Order Editor support thread.

Link to comment
Share on other sites

So I got silly and changed the way WPP modifies checkout_shipping.php and checkout_confirmation.php.

 

Since going back to PayPal to edit the shipping address isn't going to do the user much good as the website won't accept this information if they have any pre-existing info in the database (and they've already authorized a payment to be made), and who wants to enter their password in again anyway, I did this:

 

1) Changed the code for the "Change Address" button on checkout_shipping.php as so:

 

  <? //---PayPal WPP Modification START ---//-- ?>
<?php //if ($ec_checkout && $ec_enabled) { 
// I commented out this mod in an attempt to get the shipping address snafu corrected?>
			<!--td class="main" width="50%" valign="top"><?//php echo TEXT_CHOOSE_SHIPPING_DESTINATION . '<br><br><a href="' . tep_href_link(FILENAME_EC_PROCESS, 'clearSess=1', 'SSL') . '">' . tep_image_button('button_change_address.gif', IMAGE_BUTTON_CHANGE_ADDRESS) . '</a>'; ?></td-->
<?php //} else { ?>
			<td class="main" width="50%" valign="top"><?php echo TEXT_CHOOSE_SHIPPING_DESTINATION . '<br><br><a href="' . tep_href_link(FILENAME_CHECKOUT_SHIPPING_ADDRESS, '', 'SSL') . '">' . tep_image_button('button_change_address.gif', IMAGE_BUTTON_CHANGE_ADDRESS) . '</a>'; ?></td>
<?php //} ?>
<? //---PayPal WPP Modification END ---//-- ?>

 

this maintains the code for future use while, at the same time, reverting to it's previous functionality of allowing the user to go to the website address book if they want to change the shipping address.

 

2) Changed the code for the tep_address_label function in checkout_shipping.php as so:

 

<? //---PayPal WPP Modification START ---//-- ?>
<?php /*
//This has been commented out in an attempt to get the shipping address snafu corrected
		if ($ec_checkout && $ec_enabled) { 
			$paypal_ec_payer_info = $_SESSION['paypal_ec_payer_info'];
			$address_label = $paypal_ec_payer_info['payer_firstname'] . ' ' . $paypal_ec_payer_info['payer_lastname'] . '<br>';
			if ($paypal_ec_payer_info['payer_business']) $address_label .= $paypal_ec_payer_info['payer_business'].'<br>';
			$address_label .= $paypal_ec_payer_info['ship_street_1'] . '<br>';
			if ($paypal_ec_payer_info['ship_street_2']) $address_label .= $paypal_ec_payer_info['ship_street_2'].'<br>';
			$address_label .= $paypal_ec_payer_info['ship_city'] . ', ' . $paypal_ec_payer_info['ship_state'] . '  ' . $paypal_ec_payer_info['ship_postal_code'] . '<br>';
			$address_label .= $paypal_ec_payer_info['ship_country_name'];
*/
?>
				<!--td class="main" valign="top"><?//php echo $address_label; ?></td-->
<?php //} else { ?>
				<td class="main" valign="top"><?php echo tep_address_label($customer_id, $sendto, true, ' ', '<br>'); ?></td>
<?php //} ?>
<? //---PayPal WPP Modification END ---//-- ?>

 

once again the code is still there for any possible future use, but it's pretty well neutered. For this step I either made a mistake or missed something as the shipping address sent from PayPal still shows up on this page when the user returns from PayPal.

 

3) In checkout_confirmation.php I reverted the edit shipping address link (similar to step 1):

 

 <? //---PayPal WPP Modification START ---//-- ?>
<?php //if ($ec_checkout && $ec_enabled) { 
// I commented this out in an attempt to get the shipping address snafu cleared up ?>
			<!--td class="main"><?//php echo '<b>' . HEADING_DELIVERY_ADDRESS . '</b> <a href="' . tep_href_link(FILENAME_EC_PROCESS, 'clearSess=1', 'SSL') . '"><span class="orderEdit">(' . TEXT_EDIT . ')</span></a>'; ?></td-->
<?php //} else { ?>
			<td class="main"><?php echo '<b>' . HEADING_DELIVERY_ADDRESS . '</b> <a href="' . tep_href_link(FILENAME_CHECKOUT_SHIPPING_ADDRESS, '', 'SSL') . '"><span class="orderEdit">(' . TEXT_EDIT . ')</span></a>'; ?></td>
<?php //} ?>
<? //---PayPal WPP Modification END ---//-- ?>

 

These steps do not truly fix the problem, but they do allow the user to edit the addresses shown in the checkout process, thus helping to ensure the correct data is populated in the order information.

Do, or do not. There is no try.

 

Order Editor 5.0.6 "Ultra Violet" is now available!

For support or to post comments, suggestions, etc, please visit the Order Editor support thread.

Link to comment
Share on other sites

Problem:

 

When a first-time user (a user with no pre-existing information in the database) checks out using EC, as they first see the checkout_shipping page they're presented with an error message generated by Multi Vendor Shipping instructing them that they must select a shipping method for each class of goods. This error message should appear if they have been redirected to the page (ostensibly from checkout_payment.php) after having failed to select a shipping method or methods (a default shipping method should be pre-selected for all classes of goods, but the error process exists anyway just in case).

 

The code in question is

 

// MVS v4.0
//if no shipping method has been selected, redirect the customer to the shipping method selection page
if (($cart->content_type !== 'virtual') ||
 ($total_weight > 0 )){
if (count($shipping['vendor']) != count($cart->vendor_shipping)) {
tep_redirect(tep_href_link(FILENAME_CHECKOUT_SHIPPING, 'error_message=' . ERROR_NO_SHIPPING_SELECTED_SELECTED . ERROR_NO_SHIPPING_SELECTED_SELECTED_MORE, 'SSL'));
}
} //MVS end

 

and is found directly above

 

// load all enabled payment modules

 

in checkout_payment.php.

 

I suppose I could add

 

&& (!$ec_checkout)

 

to it but then it won't work for EC customers.

Do, or do not. There is no try.

 

Order Editor 5.0.6 "Ultra Violet" is now available!

For support or to post comments, suggestions, etc, please visit the Order Editor support thread.

Link to comment
Share on other sites

I didn't put a smilie on my comment, but I'm sure you know that was written with tongue planted firmly in cheek.

 

--Glen

 

Heh, no worries, as was mine.

 

 

Why are the modifications written so that once a user is in the EC flow, any attempt to change the shipping address redirects them to ec_process?

 

It seems to me, IMHO, that once they've authorized the charge to their PayPal account, they should be able to modify the address information provided at checkout without going back to PayPal.

 

Wouldn't allowing the user to modify the shipping address via osC effectively override the shipping address sent from PayPal?

 

 

That's the behavior that PayPal suggests for EC users who want to change their address. I see what you mean about leaving it more in-house, though.

 

Does this version fix the International (state) address errors, as suggested previously?

 

More or less. SteveDallas showed me that there are four or five countries that should have a blank state field, so I've added his fix for that. Otherwise, as long as the customer fills in their address information correctly, it should work. I would like to hear some results (successful and unsuccessful)!

 

Brian-

 

The way you've written this, should a temporary account be deleted upon reaching checkout_success.php, or only when the user clicks on the continue button on that page?

 

Cheers

Stew

 

It's deleted near the end of the checkout_success.php page after all of the order entry queries have finished.

Please use the forums for support! I am happy to help you here, but I am unable to offer free technical support over instant messenger or e-mail.

Link to comment
Share on other sites

if (count($shipping['vendor']) != count($cart->vendor_shipping)) {

tep_redirect(tep_href_link(FILENAME_CHECKOUT_SHIPPING, 'error_message=' . ERROR_NO_SHIPPING_SELECTED_SELECTED . ERROR_NO_SHIPPING_SELECTED_SELECTED_MORE, 'SSL'));

}

 

 

You would need to modify the WPP module to fill in the $cart->vendor_shipping value in the ec_step2() function. It's looking for an array, and since I have no idea what format it expects, I can't offer any advice. I'm working on a site now that will eventually need Multi Vendor shipping, so if you can wait, I'll post a fix when I get to it.

Please use the forums for support! I am happy to help you here, but I am unable to offer free technical support over instant messenger or e-mail.

Link to comment
Share on other sites

You would need to modify the WPP module to fill in the $cart->vendor_shipping value in the ec_step2() function. It's looking for an array, and since I have no idea what format it expects, I can't offer any advice. I'm working on a site now that will eventually need Multi Vendor shipping, so if you can wait, I'll post a fix when I get to it.

 

Wouldn't that disable the functionality of the code?

 

Is the user being redirected from checkout_payment.php when they are first delivered to checkout_shipping.php? I thought they were being redirected from ec_process.php.

Edited by djmonkey1

Do, or do not. There is no try.

 

Order Editor 5.0.6 "Ultra Violet" is now available!

For support or to post comments, suggestions, etc, please visit the Order Editor support thread.

Link to comment
Share on other sites

That was just a guess looking at the block of code you posted. If there was an error trying to charge the card, they'll get sent back to checkout_payment. That's the only thing I can think of.

 

 

Side note: People have been complaining that the shipping address doesn't get sent for as long as the module's been around, and now that it's fixed get an email from a store that sells only virtual products and the checkout process fails everytime because there are no shipping address. I just can't win! Anyway, for those of you with virtual products, this should fix your problem:

 

In includes/modules/payment/paypal_wpp.php, delete this block of code:

 

// Begin ShippingAddress -- WILLBRAND //

$sat =& Services_PayPal::getType('AddressType');

$sat->setName($order->delivery['firstname'] . ' ' . $order->delivery['lastname']);

$sat->setStreet1($order->delivery['street_address']);

$sat->setStreet2($order->delivery['suburb']);

$sat->setCityName($order->delivery['city']);

$sat->setPostalCode($order->delivery['postcode']);

$sat->setStateOrProvince($order->delivery['state']);

$sat->setCountry($order->delivery['country']['iso_code_2']);

// End ShippingAddress -- WILLBRAND //

 

And then delete this line:

 

$pdt->setShipToAddress($sat);

 

 

There are more elegant ways to do it, but this is a quick fix until then. If you make this change, the shipping address will no longer be sent to PayPal.

Please use the forums for support! I am happy to help you here, but I am unable to offer free technical support over instant messenger or e-mail.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...