Jump to content

hantaah

New Members
  • Posts

    2
  • Joined

  • Last visited

hantaah's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. Please please please I really hope someone can help me as I'm trying to setup a donation centre as directed by this tutorial: http://tutorialzine.com/2010/05/donation-center-php-mysql-paypal-api/ The problem with this tutorial is that it is very vague. I have put in all the xhtml and added the two databases. I have placed all the .php files side by side in this directory: http://sakeenaheducationcentre.com/wp-content/themes/StyleShop I have placed this in the head: <?php require "http://sakeenaheducationcentre.com/wp-content/themes/StyleShop/config.php"; require "http://sakeenaheducationcentre.com/wp-content/themes/StyleShop"; // Determining the URL of the page: $url = 'http://'.$_SERVER['SERVER_NAME'].dirname($_SERVER["REQUEST_URI"]); // Fetching the number and the sum of the donations: list($number,$sum) = mysql_fetch_array(mysql_query("SELECT COUNT(*),SUM(amount) FROM dc_donations")); // Calculating how many percent of the goal were met: $percent = round(min(100*($sum/$goal),100)); // Building a URL with Google's Chart API: $chartURL = 'http://chart.apis.google.com/chart?chf=bg,s,f9faf7&cht=p&chd=t:'.$percent.',-'.(100-$percent).'&chs=200x200&chco=639600&chp=1.57'; ?> ------------------------------------------------------------------------------------------------------------------ I Just don't know what to do to get it to work - It's corrently in demo mode but I can't seem to even donate in demo mode or get the green chart up. I'm also not sure what info to add where for real donations. I'm not sure about the paypal_class and assigning it PayPal’s URLor about calling the $p->validate_ipn() I'd really really appreciate a nudge in the right direction, I've been working on it for such a long time, although I've figured quite a lot out and progressed with some thinking I'm not at a stand still. I really hope you can help Many Thanks my page is http://www.sakeenaheducationcentre.com/our-mission
  2. I am new to php and I'm trying to make a donation centre in my new site here: http://www.sakeenaheducationcentre.com/our-mission/ I'm a little confused as to what goes exactly where so would really appreciate a good nudge in the right direction. So far I have: -added two tables to my database ( dc_donations and dc_comments. The first stores the donation data which is passed in a request from PayPal, The second table holds the information about the donors, which they fill for themselves on the thank you page. ) -Added the xhtml to the html input field in the wordpress " pages " section ( There is php code there so I'm not sure if this code goes here, if not where should I place it? ) -All the php files I have placed side by side with all my other php files such as home.php / footer.php etc. The files incude: config.php ( with paypal config details ) connect.php ( with database connection details ) and content.php With regards to these files how do I call to them from the xhtml? Are they in the right place?# Many thanks for any help in advance
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.