Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $sql = "SELECT firstname, lastname, email, phone, username, password, status,
- memberview, statuschangedate FROM csvdata ORDER BY lastname ";
- $sth= $DBH->prepare($sql);
- $sth->execute();
- while ($row = $sth->fetch(PDO::FETCH_ASSOC)) {
- code
- }
- $sql = "SELECT firstname, lastname, email, phone, username, password, status, memberview, statuschangedate FROM csvdata ORDER BY lastname ";
- $sth= $DBH->prepare($sql);
- $sth->execute();
- $i = 0;
- echo "<table class='alltable'>
- <tr class='firsttr' style='background:gray;'>
- <td>First Name </td>
- <td>Last Name </td>
- <td>Email </td>
- <td>Phone </td>
- <td>Username </td>
- <td>Password </td>
- <td>Status </td>
- <td>Memberview</td>
- <td>Status Change Date</td>
- <td>#</td>
- </tr>
- ";
- $j = 0;
- while ($row = $sth->fetch(PDO::FETCH_ASSOC)) {
- $csvfirst = $row;
- $csvfirstname = $csvfirst['firstname'];
- $csvlastname = $csvfirst['lastname'];
- $csvemail = $csvfirst['email'];
- $csvphone = $csvfirst['phone'];
- $csvusername = $csvfirst['username'];
- $csvpassword= $csvfirst['password'];
- $csvstatus = $csvfirst['status'];
- $csvmemberview = $csvfirst['memberview'];
- $csvstatuschange = $csvfirst['statuschangedate'];
- $memberfirstnamearray[$j] = $csvfirstname;
- $memberlastnamearray[$j] = $csvlastname;
- $memberemailarray[$j] = $csvemail;
- $memberphonearray[$j] = $csvphone;
- $j++;
- $i++;
- echo "
- <tr>
- <td>
- $csvfirstname
- </td>
- <td>
- $csvlastname
- </td>
- <td>
- $csvemail
- </td>
- <td>
- $csvphone
- </td>
- <td>
- $csvusername
- </td>
- <td>
- $csvpassword
- </td>
- <td>
- $csvstatus
- </td>
- <td>
- $csvmemberview
- </td>
- <td>
- $csvstatuschange
- </td>
- <td>
- $i
- </td>
- </tr>
- ";
- }
- $_SESSION['firstnameexport'] = $memberfirstnamearray;
- $_SESSION['lastnameexport'] = $memberlastnamearray;
- $_SESSION['emailexport'] = $memberemailarray;
- $_SESSION['phoneexport'] = $memberphonearray;
- $_SESSION['num'] = $j;
- echo "
- </table>";
- }
- 'id', 'int(11)', 'NO', 'PRI', NULL, 'auto_increment'
- 'firstname', 'varchar(105)', 'YES', '', NULL, ''
- 'lastname', 'varchar(105)', 'YES', '', NULL, ''
- 'email', 'varchar(105)', 'YES', '', NULL, ''
- 'phone', 'varchar(105)', 'YES', '', NULL, ''
- 'username', 'varchar(105)', 'YES', '', NULL, ''
- 'password', 'varchar(105)', 'YES', '', NULL, ''
- 'status', 'varchar(105)', 'YES', '', NULL, ''
- 'memberview', 'varchar(105)', 'YES', '', NULL, ''
- 'statuschangedate', 'varchar(105)', 'YES', '', NULL, ''
- 'notes', 'varchar(1000)', 'YES', '', NULL, ''
- 'customernotes', 'varchar(1000)', 'YES', '', NULL, ''
- <script>
- $(".viewall").click(function () {
- //dropdown.bind('change', function(){
- //$(".alltable").slideDown(0,function(){
- //});
- $(".alltable").css("display", "table");
- $(".alltable tr").css("display", "table-row");
- $(".alltable td").css("display", "table-cell");
- //$(".alltable tr").slideDown(0,function(){
- //});
- //$(".alltable td").slideDown(0,function(){
- //});
- });
- $(".closeall").click(function () {
- //dropdown.bind('change', function(){
- /*$(".alltable").slideUp(200,function(){
- });*/
- $(".alltable").css("display", "none");
- $(".alltable tr").css("display", "none");
- $(".alltable td").css("display", "none");
- /*$(".alltable tr").slideUp(200,function(){
- });
- $(".alltable td").slideUp(200,function(){
- });*/
- });
- </script>
Add Comment
Please, Sign In to add comment