From 55751e5da8f0460f9851d82a87eaac5ea9f175cb Mon Sep 17 00:00:00 2001 From: jacob Date: Fri, 2 Oct 2009 13:32:21 +0000 Subject: [PATCH] hide the list of donors after finding one starting a form for adding contacts --- admin/donors.php | 95 ++++++++++++++++++++++++++++++++++++++++++------ 1 file changed, 84 insertions(+), 11 deletions(-) diff --git a/admin/donors.php b/admin/donors.php index 7d1da3c..b9b4ecd 100644 --- a/admin/donors.php +++ b/admin/donors.php @@ -78,6 +78,87 @@ break; case 'contactsinfo_load': + draw_contactsinfo_form(); + exit; + break; + + case 'contactsinfo_save': + $u = user_create('sponsor', $_POST['email']); + + $u['salutation']=$_POST['salutation']; + $u['firstname']=$_POST['firstname']; + $u['lastname']=$_POST['lastname']; + $u['position']=$_POST['position']; + $u['phonework']=$_POST['phonework']; + $u['phonecell']=$_POST['phonecell']; + $u['phonehome']=$_POST['phonehome']; + $u['fax']=$_POST['fax']; + $u['email']=$_POST['email']; +// $u['notes']=$_POST['notes']; +// $u['sponsors_id']=$sponsors_id; + user_save($u); +// happy_("happy!"); + + exit; + break; + } + + send_header("Donor Management", + array('Committee Main' => 'committee_main.php', + 'Administration' => 'admin/index.php', + 'Fundraising' => 'admin/fundraising.php') + ); + +function draw_contactsinfo_form(){ + // use a basic form for now and beautify later +?> +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +*/ ?> + +
+ " onClick="return contactsinfo_save()" /> +
+ +
+\n"; } echo "\n"; - - exit; - break; - } - - send_header("Donor Management", - array('Committee Main' => 'committee_main.php', - 'Administration' => 'admin/index.php', - 'Fundraising' => 'admin/fundraising.php') - ); +*/ +} ?>