PDA

View Full Version : Miscellaneous Hacks - Add extra info to the PayPal Subscription Email


DaveS
02-06-2011, 10:00 PM
There was a previous mod that I used on my forum that added the UserName and UserId to the PayPal email that was sent. I found this information useful if I needed to check anything with a subscription.
https://vborg.vbsupport.ru/showthread.php?t=99421
All credit to Luroca the original contributor.
I recently upgraded from 3.8 to 4.1 and wanted the same functionality and this simple mod hadn't yet been release anywhere so I set about working out the changes that I needed to make in the new vB4 template system.

Before:

Site Sponsor Subscription
Item Number 0c8cbc5d1bc869922341c3fbb37767a9 14.00 EUR


After:

Site Sponsor Subscription of TestUser (1125)
Item Number 0c8cbc5d1bc869922341c3fbb37767a9 14.00 EUR

So after the type of subscription the UserName and the UserId are appended.

In the Subscriptions (Paid) Templates group find the subscription_payment_paypal template.
Find the line:
<input type="hidden" name="item_name" value="{vb:rawphrase x_subscription, {vb:raw subinfo.title}}" />

and replace with:

<input type="hidden" name="item_name" value="{vb:rawphrase x_subscription, {vb:raw subinfo.title}} of {vb:raw userinfo.username} ({vb:raw userinfo.userid})" />

Hope this is useful to some of you. :D

stained
02-07-2011, 09:09 PM
Thank you :)

Davey-UK
06-24-2011, 04:55 AM
Brilliant. Ive been looking for this. Now just wait till a buyer pops up to test it. :):up:

stained
06-24-2011, 10:41 AM
Just as a preliminary confidence check for you Davey, I can confirm that this is working correctly in 4.1.4. Here's one from yesterday :

22. Jun 2011 07:40:42 PDT
Transaction ID: xxxxxxxxxxxxxxxxxx

Hello xxxxxxxxxxx,

You received a payment of €xxxx EUR from xxxx xxxxxxxx (xxxxx.xxxxxxxxxx@yahoo.com)
You can now ship any items. To see all the transaction details, log in to your PayPal account.

It may take a few moments for this transaction to appear in your account.

Seller Protection - Not Eligible


--------------------------------------------------------------------------------

Buyer
xxxxxx xxxxxxxxx
xxxxx.xxxxxxxxxx@yahoo.com
Instructions to merchant
The buyer hasn't entered any instructions.

Full Member Subscription of xxxxxxx (1331)
Item# xxxxxxxxxxxxxxxxxxxxxxxxxxx xxxx EUR 1 xxxx EUR
Subtotal xxxx EUR
Total €xxxx EUR
Payment €xxxx EUR
Payment sent to yyyy.yyyyyyy@yyyyyy.com

BadgerDog
07-11-2011, 10:29 PM
Has anyone had a problem with this breaking the PayPal acknowledgement of payments vBulletin routine?

Thanks for any feedback ... :)

Regards,
Doug

DaveS
07-12-2011, 04:10 AM
Has anyone had a problem with this breaking the PayPal acknowledgement of payments vBulletin routine?

Thanks for any feedback ... :)

Regards,
Doug
No. I get several subscriptions a day and I'm on 4.1.4 with no problems.

as7apcool
07-12-2011, 05:18 PM
Thank you

chrisngrod
03-16-2012, 05:52 PM
I actually stumbled upon this. Thanks a lot. It's very helpful when dealing with Paypal complaints.