We have a website for donations to children who needs heart surgerys, I want to move the website to Drupal. In the current website the database is connected to the payment page so whenever a donation is made the amount needed for each child is reduced. Is there a module that I can use to manage the children's data and link it to a payment gateway? Or is there something close to what I need?

this is the website: http://www.shevet.org

Rahif Abboud
http://www.perfect-cv.com

Comments

ram_segal’s picture

Hey,

I don't know a module that can help you specific, I would do it like this:
First you must install cck module to your new drupal site, create a new content type - lets say - 'child', with fields like money_needed, etc.
Copy all child information you have on your DB to your drupal DB - by running once a huge query or running once code like this:

pseudo code:

childs = sql query on all childs in your DB
for every child in childs
#create a new child node in drupal:

$child = new StdClass();
$child->type = 'child';
$child->title = child->field_name;
$child->status = 1;
$child->uid = 1;
$child->field_money_needed = child->money_needed;
#all other field u need
node_save($child);

now u can build a function that receives child node nid, and amount to reduce:

function reduce_amount($nid,$amount){
$child = node_load($nid);
$child->money_needed = $child->money_needed - $amount;
# other actions..
node_save($child);
}

u call this function each time u receive payment.

if you have questions i'll be happy to answer.

Ram Segal
Sergata ltd

MacRonin’s picture

Depending on your other requirements it may be over-kill, but you might want to take a look at CiviCRM( http://civicrm.org/ ) especially their upcoming Personal Contribution Pages ( http://civicrm.org/node/482 ) Their basic donation page function can do what you describe, but PCP can take it much further.

Once you set up your contribution page and enable PCP for it, people will be able to start their own personal campaigns in support of your effort. They will be able to set up a page with their own text and photos, set their personal fundraising goal amount, and off they go - the can start campaigning in your name. They can send off a limited quantity of emails to their personal networks (through Tell-a-Friend functionality). All the contributions that they attract will be made through your contribution page of course, but they will be able to take the credit thanks to the personal campaign thermometer and honour roll on their "website". And of course they'll have a lot of satisfaction from participating in your campaign effort.

-------------------
http://www.PrivacyDigest.com/ News from the Privacy Front (Drupal)
http://www.SunflowerChildren.org/ Helping children around the world ( Drupal)