Update maryland_voter.php
[clinton/MarylandElectronicPetitionSignature.git] / is_the_information_correct.php
1 <?PHP
2 $web_first_name = $_COOKIE['web_first_name'];
3 $web_last_name = $_COOKIE['web_last_name'];
4 $web_house_number = $_COOKIE['web_house_number'];
5 $web_zip_code = $_COOKIE['web_zip_code'];
6 $DOB = $_COOKIE['pDOB'];
7 $PHONE = $_COOKIE['pPHONE'];
8 if ($web_first_name != '' && $web_last_name != '' && $web_house_number != '' && $web_zip_code != ''){
9 include_once('header.php');
10 $web_first_name = $petition->real_escape_string($web_first_name);
11 $web_last_name = $petition->real_escape_string($web_last_name);
12 $web_house_number = $petition->real_escape_string($web_house_number);
13 $web_zip_code = $petition->real_escape_string($web_zip_code);
14 $DOB = $petition->real_escape_string($DOB);
15 $PHONE = $petition->real_escape_string($PHONE);
16 }else{
17 header('Location: warning_incomplete.php');
18 }
19 $q = "select * from VoterList where LASTNAME = '$web_last_name' and FIRSTNAME = '$web_first_name' and HOUSE_NUMBER = '$web_house_number' and RESIDENTIALZIP5 = '$web_zip_code'";
20 $r = $petition->query($q);
21 $d = mysqli_fetch_array($r);
22 if ($d['VTRID'] != ''){
23 $VTRID = $d['VTRID'];
24 $FIRSTNAME = $d['FIRSTNAME'];
25 $MIDDLENAME = $d['MIDDLENAME'];
26 if ($MIDDLENAME == ''){
27 slack_general_admin("WARN: Blank Middle Name Detected",'md-petition-signed');
28 }
29 $LASTNAME = $d['LASTNAME'];
30 $pos = strpos($LASTNAME, '-');
31 if ($pos !== false) {
32 slack_general_admin("WARN: Hyphen in Last Name Detected",'md-petition-signed');
33 }
34 $ADDRESS = $d['ADDRESS'];
35 $RESIDENTIALCITY = $d['RESIDENTIALCITY'];
36 $COUNTY = $d['COUNTY'];
37 $RESIDENTIALZIP5 = $d['RESIDENTIALZIP5'];
38 // set cookies for hard_copy.php
39 setcookie("pCOUNTY", $COUNTY);
40 if ($MIDDLENAME == ''){
41 setcookie("pNAME", "$FIRSTNAME $LASTNAME");
42 }else{
43 setcookie("pNAME", "$FIRSTNAME $MIDDLENAME $LASTNAME");
44 }
45 setcookie("pADDRESS", "$ADDRESS $RESIDENTIALCITY $RESIDENTIALZIP5");
46 setcookie("pADDRESS1", "$ADDRESS");
47 setcookie("pADDRESS2", "$RESIDENTIALCITY MD $RESIDENTIALZIP5");
48 setcookie("pVTRID", $VTRID);
49 setcookie("signature_status", 'verified');
50 slack_general('MATCH: Is the information correct ('.$FIRSTNAME.' '.$LASTNAME.' '.$RESIDENTIALCITY.') ('.$_COOKIE['invite'].')','md-petition');
51 }else{
52 slack_general('MISS: Is the information correct ('.$web_first_name.' '.$web_last_name.' '.$PHONE.') ('.$_COOKIE['invite'].')','md-petition');
53 setcookie("signature_status", 'notfound');
54 header('Location: warning_not_found.php');
55 }
56 $qX = "select * from website_text where id = '6'";
57 $rX = $petition->query($qX);
58 $dX = mysqli_fetch_array($rX);
59 ?>
60 <script>document.title = "MEPS - Confirm information";</script>
61 <div class='row'>
62 <div class='col-sm-10' style='text-align:center;'><h1><?PHP echo $dX['text_title'];?></h1><h2><?PHP echo $dX['text_block'];?></h2></div>
63 </div>
64 <div class='row'>
65 <div class='col-sm-10'><button type="button" class="btn btn-success btn-lg btn-block" onclick="window.location.href='eligible.php'"><img alt='Click Here to Continue' class='click_me' src="files/click_here.gif">YES</button></div>
66 </div>
67 <div class='row'>
68 <div class='col-sm-5' style='text-align:right;'><h2>First Name</h2></div>
69 <div class='col-sm-5' style='text-align:left;'><h2><?PHP echo $FIRSTNAME;?></h2></div>
70 </div>
71 <div class='row'>
72 <div class='col-sm-5' style='text-align:right;'><h2>Middle Name</h2></div>
73 <div class='col-sm-5' style='text-align:left;'><h2><?PHP echo $MIDDLENAME;?><h2></div>
74 </div>
75 <div class='row'>
76 <div class='col-sm-5' style='text-align:right;'><h2>Last Name</h2></div>
77 <div class='col-sm-5' style='text-align:left;'><h2><?PHP echo $LASTNAME;?></h2></div>
78 </div>
79 <div class='row'>
80 <div class='col-sm-5' style='text-align:right;'><h2>Date of Birth</h2></div>
81 <div class='col-sm-5' style='text-align:left;'><h2><?PHP echo $DOB;?></h2></div>
82 </div>
83 <div class='row'>
84 <div class='col-sm-5' style='text-align:right;'><h2>Full Addresss</h2></div>
85 <div class='col-sm-5' style='text-align:left;'><h2><?PHP echo $ADDRESS;?></h2></div>
86 </div>
87 <div class='row'>
88 <div class='col-sm-5' style='text-align:right;'><h2>Phone</h2></div>
89 <div class='col-sm-5' style='text-align:left;'><h2><?PHP echo $PHONE;?></h2></div>
90 </div>
91 <div class='row'>
92 <div class='col-sm-5' style='text-align:right;'><h2>City</h2></div>
93 <div class='col-sm-5' style='text-align:left;'><h2><?PHP echo $RESIDENTIALCITY;?></h2></div>
94 </div>
95 <div class='row'>
96 <div class='col-sm-5' style='text-align:right;'><h2>County</h2></div>
97 <div class='col-sm-5' style='text-align:left;'><h2><?PHP echo $COUNTY;?></h2></div>
98 </div>
99 <div class='row'>
100 <div class='col-sm-5' style='text-align:right;'><h2>Zip</h2></div>
101 <div class='col-sm-5' style='text-align:left;'><h2><?PHP echo $RESIDENTIALZIP5;?></h2></div>
102 </div>
103 <div class='row'>
104 <div class='col-sm-10'><button type="button" class="btn btn-success btn-lg btn-block" onclick="window.location.href='eligible.php'"><img alt='Click Here to Continue' class='click_me' src="files/click_here.gif">YES</button></div>
105 </div>
106 <div class='row'>
107 <div class='col-sm-10'><button type="button" class="btn btn-danger btn-lg btn-block not_me" onclick="window.location.href='reset.php'">NO</button></div>
108 </div>
109
110 <?PHP include_once('footer.php');