Пример #1
0
}
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Donation Status</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link rel="stylesheet" media="screen" href="assets/style.css" /> 
<script type="text/javascript" src="assets/scripts/jquery.min.js"></script>
<script type="text/javascript" src="assets/scripts/common/jquery.scrollTo-min.js"></script>
</head>

<body>
    	<div class="wrapper">    
           
            <h1><?php 
echo $messageData['heading'];
?>
</h1> 
            <p><?php 
echo $messageData['message'];
?>
</p>
            
            <br /><a href="<?php 
echo DonationConfig::get('site_url');
?>
"><strong>Want to donate more?</strong></a>
        </div>
</body>
</html>
<?php

/**
 * Form Handler
 *
 * @author      Sam Plugins <*****@*****.**>
 * @copyright   Sam Plugins <*****@*****.**>
 * @twitter     http://twitter.com/samplugins
 */
require_once "include/init.php";
$cmd = new clsPayPalDonationHandler();
$data = array();
$data['item_name'] = Settings::Get('donation_statement_title');
$data['currency_code'] = DonationConfig::Get('currency');
$cmd->setData($data)->donate();
 protected function getLink($page = '')
 {
     $str = DonationConfig::get('site_url');
     if ($page != '') {
         $str = $str . $page;
     }
     return $str;
 }
        <td width="80%"><?php 
echo $request_data['last_name'];
?>
</td>
    </tr>
     <tr class="datarow_even">
          <td width="20%"><label>Email</label></td>
        <td width="80%"><?php 
echo $request_data['email'];
?>
</td>
    </tr> 
      <tr class="datarow_odd">
        <td width="20%"><label>Amount</label></td>
        <td width="80%"><?php 
echo DonationConfig::get('currency');
?>
 <?php 
echo $request_data['amount'];
?>
</td>
    </tr>
    <tr class="datarow_even">
          <td width="20%"><label>IP Address</label></td>
        <td width="80%"><?php 
echo $request_data['ip_address'];
?>
</td>
    </tr> 
     <tr class="datarow_even">
          <td width="20%"><label>Payment Method</label></td>
 private function _payment_completed_mail($donation_data)
 {
     $Mail = new clsMail();
     $fromName = Settings::Get('from_name');
     $no_reply = Settings::Get('no_reply_email');
     $contact_to_email = explode(',', Settings::Get('to_email'));
     $reply_to = Settings::Get('reply_to');
     $Mail->IsHTML(true);
     $Mail->prep_headers($fromName, $no_reply);
     $Mail->setSubject("Online Payment Completed By " . $donation_data['first_name'] . " " . $donation_data['last_name'] . "");
     $message = "<html><body><table cellpadding='0' cellspacing='0' width='100%'>";
     $message .= "<tr><td width='30%'>First Name</td><td width='70%' colspan='2'>" . $donation_data['first_name'] . "</td></tr>";
     $message .= "<tr><td width='30%'>Last Name</td><td width='70%' colspan='2'>" . $donation_data['last_name'] . "</td></tr>";
     $message .= "<tr><td width='30%'>Email</td><td width='70%' colspan='2'>" . $donation_data['email'] . "</td></tr>";
     $message .= "<tr><td width='30%'>Payment Status</td><td width='70%' colspan='2'>" . strtoupper($donation_data['status_id']) . "</td></tr>";
     $message .= "<tr><td width='30%'>More Details:</td><td width='70%' colspan='2'><a href='" . DonationConfig::get('site_url') . "php/view.php?id=" . $donation_data['donation_id'] . "'>Click here</a></td></tr>";
     $message .= "<tr><td>IP Address</td><td colspan='2'>" . $donation_data['ip_address'] . "</td></tr></table></body></html>";
     $Mail->setMessage($message);
     // Email form to multiple email addresses - Added on: 14/April/2011
     foreach ($contact_to_email as $k => $to_email) {
         @$Mail->send($to_email);
     }
     $subject = '[' . Settings::get('donation_statement_title') . '] Your Donation';
     if (Settings::get('subject') != '') {
         $subject = Settings::get('subject');
     }
     $message = Settings::Get('message');
     $message = str_replace('[NAME]', $donation_data['first_name'] . ' ' . $donation_data['last_name'], $message);
     $message = str_replace('[DATE]', CommonFunc::getFormatedDateTime($donation_data['donation_date']), $message);
     $message = str_replace('[STATUS]', strtoupper($donation_data['status_id']), $message);
     $Mail->prep_headers($fromName, $reply_to);
     $Mail->setSubject($subject);
     $Mail->setMessage($message);
     @$Mail->send($donation_data['email']);
 }