Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- ini_set('display_errors',1);
- ini_set('display_startup_errors',1);
- error_reporting(-1);
- include_once('includes/connect.php');
- $q = $db->prepare("SELECT COUNT(id) as records FROM tracker WHERE id = ?");
- $q->execute(array($id));
- $records = (int) $q->fetch(PDO::FETCH_OBJ)->records;
- $query = $db->query("SELECT `id`, `votNumber`, `first_last`, `phone`, `city`, `active`, `gender`, `birth_year`, `registration_date` FROM `members` WHERE `id` = $records");
- while($rows = $query->fetch(PDO::FETCH_ASSOC)){
- echo $rows['id'] . '<br/>';
- echo $rows['votNumber'].'<br/>';
- echo $rows['first_last'].'<br/>';
- echo $rows['phone'].'<br/>';
- echo $rows['city'] . '<br/>';
- echo $rows['active'].'<br/>';
- echo $rows['gender'].'<br/>';
- echo $rows['birth_year'].'<br/>';
- echo $rows['registration_date'].'<br/>';
- }
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement