It would be very helpful (and increase the functionality) if this module could pass an "Amount" field in the webform through to Paypal. So when the paypal screen opens up the amount would already be displayed.

As it currently works (unless I'm doing something wrong), the user has to indicate how much they will pay on the paypal screen.

In the future this could be used with a webform select field as well, but for now just a numeric text field would work.

Comments

mrf’s picture

Status: Active » Postponed

I'm aiming for a stable release with the current functionality before adding any new features. Once that happens I'll start on a more advanced 2.0 version. Postponing until then but would definitely welcome any patches in the meantime.

avr’s picture

@mrf,

I could be wrong, but I think with hosted buttons & "_s-xclick" as the button type, the implication is that the button is encrypted and can't be tampered with.

In order to utilize an amount from a different field, you would need to use a PayPal button type of "_xclick" (which then wouldn't use the "hosted_button_id").

Is that your understanding?

Anonymous’s picture

I found an article which seems to describe how to do this, with two caveats: it does indeed require that you set the button as 'non-encrypted' (as avr described above) and it requires that you 'generate' the button each time you edit the amount...

Article: http://www.vodahost.com/vodatalk/bluevoda-tips-tricks-shortcuts/21062-cu...

I personally wanted to use this so that the webform would have a record of the amount paid, but I'm now thinking that that might be achievable if we can get the callbacks working (#1191898: Support Paypal payment status callbacks)...

mrf’s picture

Status: Postponed » Closed (won't fix)

After thinking about this for while I think this takes this module in a direction that I'm not comfortable with.

The philosophy I'm going for with this module is a very simple ecommerce solution that offloads most of the effort (and security risk) to the paypal side. So this module is really intended for a site with a couple of one-off product or donation forms, not a site that needs a robust ecommerce solution.

If someone can put together a proof of concept for this that doesn't overly complicate things, I'll definitely take a look, but for now setting to wont fix.

avr’s picture

@mrf

You may be interested in some work i've done for a webform_commerce component. The logic is there (and could be cleaned up) to add on the fly calculation. Here's a teaser:

http://img.skitch.com/20111209-e8am6gm3rma3rpkwsq9ykxyeqg.png

https://github.com/avr/webform_commerce

Anonymous’s picture

As such this module seemed to be an interesting alternative for light "commerce" solution. But without the possibility to determine the amount in the webform it looses much of its interest.
When the user click on the paypal button he can enter the amount and this information is not stored in the result of the webform.
IO wanted to use the module for donations for an ngo. The donator fills in the project he wants to support and the amount he decides to donate. Then he finishes the process on the paypal website. When a curious user clicks on "donate" button 10 times he fills the result table of the webform and we get garbage in the result table.
I tried before the paypal donation module and it offers the simple possibility of transmitting the amount.

webform paypal would be very interesting if it is possible to add a code/description field and amount field to paypal page

nate covington’s picture

Issue summary: View changes

I just posted a similar solution that works with Drupal 7, Webform 4.

Simple Drupal Webform (v4) PayPal Integration using custom PHP confirmation message