Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- require "config.php";
- require "connect.php";
- // 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"));
- // 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';
- ?>
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
- <html xmlns="http://www.w3.org/1999/xhtml">
- <head>
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
- <title>Walkathon Sponsor Donations</title>
- <link rel="stylesheet" type="text/css" href="styles.css" />
- <script src="gen_validatorv4.js" type="text/javascript"></script>
- <!-- JQUERY MOBILE -->
- <link rel="stylesheet" href="http://code.jquery.com/mobile/1.1.0/jquery.mobile-1.1.0.min.css" />
- <script src="http://code.jquery.com/jquery-1.7.1.min.js"></script>
- <script src="http://code.jquery.com/mobile/1.1.0/jquery.mobile-1.1.0.min.js"></script>
- <script src="scripts/fastclick.js"></script> <!-- FASTCLICK -->
- </head>
- <!------------------------------- BODY ---------------------------------------------------------------->
- <body onload="initFastButtons();">
- <span id="fastclick">
- <div data-role="page" id="pageone">
- <img src="Logo.png" style="position:absolute; top: 25px; left:125px;" />
- <div id="main">
- <div class="headers">
- <h1>Inspirica & SLS Walk-A-Thon</h1>
- <h2>Donation Page</h2>
- </div>
- <div id="content">
- <div class="lightSection">
- <!-- The PayPal Donation Button -->
- <?php
- $list = "SELECT sponsoring, SUM(amount) FROM dc_donations GROUP BY sponsoring";
- $result = mysql_query("SELECT sponsoring,SUM(amount)
- FROM dc_donations
- GROUP BY sponsoring");
- $POUND = '#';
- /* Table */
- echo "<table id='resultstable'>";
- echo "<tr>";
- echo "<td width='100' align='center'>Participant</td><td width='100' align='center'>Amount of Donations</td>";
- /* Each Entry */
- while($row=mysql_fetch_array($result)) {
- echo "<tr class='tablerow'>";
- echo "<td align='left' class='leftabit' width='200'>" . /* HREF */'<a href="#' . $row['sponsoring'] . '" data-rel="dialog">' /* //HREF */. $row['sponsoring'] . "</td>" . "</a>";
- echo "<td align='center' width='200'>" . /* HREF */'<a href="#' . $row['sponsoring'] . '">' /* //HREF */. '$ '.$row['SUM(amount)'] . "</td>" . "</a>";
- echo "<br />";
- echo "</tr>";
- }
- echo "</table>";
- ?>
- </div>
- <table id="GLASS" width="861" height="200" border="0" cellpadding="0" cellspacing="0">
- <tr>
- <td>
- <a class="Homepage" href="http://StLukesCT.org/inspirica/walkathon">
- </a></td>
- <td>
- <a class="InspiricaCenter" href="http://InspiricaCT.org">
- </a></td>
- <td>
- <a class="Register" href="https://www.StLukesCT.org/podium/default.aspx?t=36644">
- </a></td>
- </tr>
- </table>
- </div>
- <div class="clear"></div>
- </div> <!-- Closing the main div -->
- </div> <!--Page -->
- <?php
- $name= $row['sponsoring'];
- $result = mysql_query("SELECT donor_first,donor_last,sponsoring,SUM(amount)
- FROM dc_donations
- GROUP BY sponsoring");
- $eachone= mysql_query("SELECT donor_last,donor_first
- FROM dc_donations"
- );
- /* ECHO THE PAGES */
- while($row=mysql_fetch_array($result)) {
- echo '<div id="'.$row['sponsoring'].'" data-role="page">';
- echo '<div data-role="header" style="height:40px;">' . '<h10>' . $row['sponsoring'] . '</h10>' . '</div>';
- /* echo $row['donor_first'] . $row['donor_last']; */
- echo 'TK';
- echo '</div>';
- }
- while($row=mysql_fetch_array($eachone)) {
- echo $row['donor_first'] . ' ' . $row['donor_last']. ' ';
- }
- ?>
- </span>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment