[ic] PayPalExpress Signature and Token?

Thomas J.M. Burton tom at globalfocusdm.com
Tue Apr 28 22:48:11 UTC 2009


Lyn St George wrote:
> On Tuesday 28 April 2009 22:17:15 Thomas J.M. Burton wrote:
>   
>> Thank you, Lyn. I appreciate you posting that information. I've been
>> working with the version Racke posted to the CVS and just about have
>> things ready for production. There is one thing that I noticed while
>> configuring this, and wanted to let you know about. Your timing with
>> this post is perfect.
>>
>> For the catalog in which I'm using this module, I'm running a
>> custom-modified version of the [total-cost] tag that works with a gift
>> certificate system I created a few years ago. I noticed when testing the
>> PaypalExpress module that if a gift certificate was used in the
>> purchase, the resulting total was not being passed to PayPal.
>>
>> In my log_transaction file, I have the following:
>>
>>     [charge route="paypalexpress" pprequest="dorequest"
>> amount="[total-cost noformat=1]" order_id="[value mv_transaction_id]"]
>>
>> which, evidently, is not correctly registering the amount attribute
>> value when interacting with the PaypalExpress module.
>>
>>
>> I traced this to line 317 in v1.0.2d of PaypalExpress.pm, which looks like:
>>
>>     my $amount =  Vend::Interpolate::total_cost() ||
>> $::Values->{amount}; # required
>>     
>
> Good catch - odd that no-one has noticed this before. The better fix is :
>
> my $amount = charge_param('amount') || Vend::Interpolate::total_cost() || 
> $::Values->{amount};
>
> (without linewrap) as it then defaults to the amount value inside the 
> [charge ..] tag. Then it won't matter if you have the 
> default "amount=[scratch tmp_remaining]" or your custom version, as either 
> will be passed through. Just for the record, the 'values amount' is meant for 
> a custom invoice/payment page where 'total_cost' is not used.
>
> This is now in the downloadable one. My logs don't show any reason why you're 
> unable to download it - perhaps you could try a different client?
Excellent, I just put that fix in and it works perfectly. Glad I was
able to help by catching that one.

I was attempting to download the files from your site via Firefox. Just
successfully grabbed them using wget on my server.

Thanks again for putting this together and for your help!

Best,
Tom

-- 
_______________________________
Global Focus Digital Media, LLC
www.globalfocusdm.com



!DSPAM:49f787a9281754802113314!





More information about the interchange-users mailing list