VirtueMart Forum

VirtueMart Dev/Coding Central: VM1 (old version) => Development Projects, Modifications, Hacks & Tweaks. VM1.1 => Payment Modules => Topic started by: TwinStripe on November 13, 2006, 07:12:36 AM

Title: I need help with a new 'pre-paid' payment module!
Post by: TwinStripe on November 13, 2006, 07:12:36 AM
Hi All,

I'm trying (despite knowing very little about PHP) to write a new payment module for VM based on the 'Vodes' Joomla/Mambo component by Emir Sakic, with a view to making a 'pay-per-download' module. I've managed to figure out what the code to increase and decrease the user's credit needs to be, but I've no idea where to put it! I tried placing it in the payment module file itself and then in the configuration box for the module in admin, and after I got it to validate (which was fun!) I still couldn't get it to perform the requested action! It wouldn't decrement the user's credits or flag to anything other than 'Pending' on orders.

I know the code itself works, because it works when inserted in to content in Joomla.

So, would I need to:

a) Give up?!?

b) Place the code in and external file and have it called as a processing/notification script.

or c) Any other suggestions?

If you need the original code to work with, you can find it at http://www.mamboxchange.com  (http://www.mamboxchange.com) and do a search for 'vodes' (the forum for it has some code too) or go to www.sakic.net (http://www.sakic.net).
Title: Re: I need help with a new 'pre-paid' payment module!
Post by: Stefaan on January 24, 2007, 18:16:17 PM
Hello,

you might have a look here:

http://virtuemart.net/index.php?option=com_smf&Itemid=71&topic=25075.msg67227#msg67227 (http://virtuemart.net/index.php?option=com_smf&Itemid=71&topic=25075.msg67227#msg67227)