Advertisement
ST3ALTHPSYCH0

multi form page

Jan 8th, 2012
51
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
HTML 4.83 KB | None | 0 0
  1. <?php
  2. include 'dbc.php';
  3. page_protect();
  4. if (isset($_SESSION['user_id'])) {?>
  5. <? }
  6. ?>
  7. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" >
  8. <html xmlns="http://www.w3.org/1999/xhtml">
  9. <head>
  10.     <title>MemoBuzz- Reaching customers where they are, when they need it! </title>
  11.       <link rel="stylesheet" type="text/css" href="./css/memobuzz.css" />
  12.     <script type="text/javascript"SRC="./javascript/dynamic_form.js"></script>
  13. </head>
  14.  
  15. <body onload="addRow('dataTable')">
  16.     <noscript>
  17.         <div class="noscript-background">
  18.         <div class="noscript-text">
  19.             <h2>
  20.                 This page requires javascript.<br/>
  21.                 Please enable javavscript, or add an exception for this page and then refresh your browser.<br/>
  22.                 See <a href="./enable-js.php#desktop">here</a> for instructions to enable javascript in popular desktop browsers.<br/>
  23.                 See <a href="./enable-js.php#mobile">here</a> for instructions to enable javascript in popular mobile browsers.
  24.             </h2>
  25.         </div>
  26.         </div>
  27.     </noscript>
  28.     <table cellpadding="10" width="100%" border="1">
  29.        
  30.         <tr valign="center">
  31.             <div class="myaccount">
  32.                 <img align="left" src="./images/logo-memobuzz.png"/>
  33.                 <p align="right">
  34.                     <strong>Welcome, <?php echo $_SESSION['user_name'];?></strong>  &#32;
  35.                     <a href="mysettings.php">Settings</a>&#149;<a href="logout.php">Logout </a>
  36.                 </p>
  37.             </div>
  38.         </tr>
  39.        
  40.         <tr bgcolor="c2dba8">
  41.             <td valign="top" width="50%">
  42.                 <h2 align="center">Contact List</h2>
  43.                 <table width="100%" border="1" bgcolor="ffffff">
  44.                     <?php
  45.                     require_once("credentials.php");
  46.                     require_once("MCSOAPClient.php");
  47.                     $group_id = mysql_fetch_row(mysql_query("select company from users where id='$_SESSION[user_id]'"));
  48.                     $arguments = array(array("Key" => "group_id", "Value" => $group_id[0]),
  49.                                         array("Key" => "first_name", "Value" => "select"),
  50.                                         array("Key" => "last_name", "Value" => "select"),
  51.                                         array("Key" => "phone_num", "Value" => "select"),
  52.                                         array("Key" => "email", "Value" => "select"));  
  53.                     $result = $MySOAPClient->DoWebService("Get", $MySOAPClient->CreateWebServiceParams("group.listmembers", $arguments));
  54.                     $groupContacts = json_decode(json_encode($result), true);
  55.                     $grouplist = $groupContacts["Data"];
  56.                         echo "<thead>";
  57.                             echo "<tr>";
  58.                                 echo "<th>Name</th>";
  59.                                 echo"<th>Phone Number</th>";
  60.                                 echo"<th>Email</th>";
  61.                             echo "</tr>";
  62.                         echo "</thead>";
  63.                             echo "<tr>";
  64.                                 echo "<td colspan = \"3\">&nbsp;</td>";
  65.                             echo "</tr>";
  66.                     for ($i = 0; $i < sizeof($grouplist); $i++) {
  67.                             echo "<tr>";
  68.                                 echo "<td>".$grouplist[$i][1]["Value"]." ".$grouplist[$i][2]["Value"]."</td>";
  69.                                 echo "<td>".$grouplist[$i][3]["Value"]."</td>";
  70.                                 echo "<td>".$grouplist[$i][4]["Value"]."</td>";
  71.                             echo "</tr>";
  72.                         }
  73.                     ?>
  74.                 </table>
  75.                 <input type="button" value="Edit Contacts" onclick='uploadCSV()'/>
  76.             </td>  
  77.             <td valign="top" width="50%">
  78.                 <h2 align="center">Bulk Messages</h2>
  79.                 <!--<form id="message" action="./group-message.php" method="post">-->
  80.                     <p align="center">
  81.                         <select name="message">
  82.                             <option value="" selected="selected"></option>
  83.                             <option value="Payment Due">Payment Due</option>
  84.                             <option value="Appointment Reminder">Appointment Reminder</option>
  85.                             <option value="Sale Today">Sale Today</option>
  86.                             <option value="5% off with this Message">5% off with this Message</option>
  87.                             <option value="Membership Renewal Notice">Membership Renewal Notice</option>
  88.                         </select>
  89.                     </p>
  90.                     <p align="center">
  91.                         <input type="submit" value="Send Message"/>&#32;
  92.                         <input type="button" value="Custom Message" onclick='uploadCSV()'/>&#32;
  93.                         <input type="button" value="New Keyword" onclick='uploadCSV()'/>
  94.                     </p>
  95.                 <!--</form>-->
  96.             </td>  
  97.         </tr>
  98.        
  99.         <tr>
  100.             <td width="60%" valign="top" colspan="2" bgcolor="c2dba8">
  101.                 <h2 align="center">Contact Upload</h2>
  102.                     <form id="upload" action="./contact-upload.php" method="post" onsubmit="submitForm()">
  103.                     <input type="button" value="Add Row" onclick="addRow('dataTable')" />
  104.                     <input type="button" value="Delete Row" onclick="deleteRow('dataTable')" />
  105.                         <input type="hidden" name="numRows" value="0" />
  106.                         <table id="dataTable" width="100%" border="1" bgcolor="ffffff">
  107.                             <thead>
  108.                                 <tr>
  109.                                     <th>Select</th>
  110.                                     <th>No.</th>
  111.                                     <th>First Name</th>
  112.                                     <th>Last Name</th>
  113.                                     <th>Mobile #</th>
  114.                                     <th>Email Address</th>
  115.                                 </tr>
  116.                             </thead>
  117.                             <tbody>
  118.                             </tbody>
  119.                         </table>
  120.                     <input type="Submit" value="Submit" />
  121.                     <input type="button" value="Upload CSV" onclick='uploadCSV()' />
  122.                     </form>
  123.             </td>
  124.         </tr>
  125.     </table>
  126. </body>
  127. </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement