News:

Support the VirtueMart project and become a member

Main Menu

I need help with a new 'pre-paid' payment module!

Started by TwinStripe, November 13, 2006, 07:12:36 AM

Previous topic - Next topic

TwinStripe

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 and do a search for 'vodes' (the forum for it has some code too) or go to www.sakic.net.