window.location.href = \"$url\";"; //slack_general('js_redirect('.$page.')','automation'); // header('Location: '.$url); //slack_general('CHECK COOKIE ('.$_COOKIE['sign_email'].') PAGE ('.$page.')','md-petition-admin'); $order = 'ASC'; setcookie("order", $order); die(); } else { //slack_general('Loop Detected for '.$_COOKIE['sign_email'],'automation'); echo "

Automated Loop Detected - Skip Setting - Reverse Sort (DESC)

"; $order = 'DESC'; setcookie("order", $order); } } if ($_COOKIE['level'] == 'user'){ slack_general('ADMIN: Redirect User Home ('.$_COOKIE['name'].') ('.$_COOKIE['level'].')','md-petition'); header('Location: user_home.php'); } if (isset($_GET['clear_php_session_id'])){ $id = $_GET['clear_php_session_id']; $petition->query("update presign set presign_status = 'DONE' where php_session_id = '$id' "); header('Location: analytics.php'); } if (isset($_GET['clear_email'])){ $email = $_GET['clear_email']; $petition->query("update presign set presign_status = 'DONE' where email_for_follow_up = '$email' "); header('Location: analytics.php'); } if (isset($_GET['sign_email'])){ $email = $_GET['sign_email']; $petition->query("update presign set presign_status = 'SIGNED' where email_for_follow_up = '$email' "); header('Location: analytics.php'); } if (isset($_GET['sign_php_session_id'])){ $id = $_GET['sign_php_session_id']; $petition->query("update presign set presign_status = 'SIGNED' where php_session_id = '$id' "); header('Location: analytics.php'); } if ($_COOKIE['level'] == 'manager'){ slack_general('ADMIN: Redirect Manager Home ('.$_COOKIE['name'].') ('.$_COOKIE['level'].')','md-petition'); header('Location: manager_home.php'); } if (isset($_GET['flag_invalid_signature'])){ $id = $_GET['flag_invalid_signature']; $petition->query("update signatures set signature_status = 'flag_invalid_signature' where id = '$id' "); header('Location: analytics.php'); } if (isset($_GET['flag_duplicate'])){ $id = $_GET['flag_duplicate']; $petition->query("update signatures set signature_status = 'flag_duplicate' where id = '$id' "); header('Location: analytics.php'); } if (isset($_GET['flag_ip_address'])){ $ip = $_GET['flag_ip_address']; $petition->query("update signatures set signature_status = 'flag_ip_address' where ip_address = '$ip' "); header('Location: analytics.php'); } if (isset($_GET['resign_requested'])){ $id = $_GET['resign_requested']; $petition->query("update signatures set signature_status = 'resign_requested' where id = '$id' "); header('Location: analytics.php'); } if (isset($_GET['bot'])){ $id = $_GET['bot']; $petition->query("update signatures set signature_status = 'bot' where id = '$id' "); header('Location: analytics.php'); } if (isset($_GET['flag_VTRID'])){ $VTRID = $_GET['flag_VTRID']; $petition->query("update signatures set signature_status = 'flag_VTRID' where VTRID = '$VTRID' "); header('Location: analytics.php'); } if (isset($_GET['flag_phone'])){ $flag_phone = $_GET['flag_phone']; $petition->query("update signatures set signature_status = 'flag_phone' where contact_phone = '$flag_phone' "); header('Location: analytics.php'); } include_once('header.php'); if (isset($_GET['ip_address'])){ $ip = $_GET['ip_address']; $petition_id = $_GET['petition_id']; echo "

Review $ip

"; $q = "SELECT * FROM signatures where ip_address = '$ip' and signature_status = 'verified' and petition_id = '$petition_id' order by signature_status desc "; $r = $petition->query($q); while($d = mysqli_fetch_array($r)){ $color = 'white'; $pos = strpos($d['date_time_signed'], date('Y-m-d')); if ($pos !== false) { $color= 'yellow'; } echo ""; } echo "
$d[date_time_signed] $d[VTRID] ".id2petition($d['petition_id'])." $d[signed_name_as] $d[signed_name_as_circulator] $d[contact_phone] $d[printed_status] flag invalid signature flag VTRID flag ip address flag duplicate contact phone resign requested bot
"; }elseif(isset($_GET['email'])){ $email = $_GET['email']; echo "

Review $email

"; $q = "SELECT * FROM presign where email_for_follow_up = '$email' order by id desc "; $r = $petition->query($q); while($d = mysqli_fetch_array($r)){ $color = 'white'; $test = date('Y-m-d',strtotime($d['action_on'])); $pos = strpos($test, date('Y-m-d')); if ($pos !== false) { $color= 'yellow'; } echo ""; } echo "
$d[action_on] $d[php_session_id] $d[php_page] ".id2petition($d['petition'])." $d[invite] $d[invite_error] $d[name] $d[email_for_follow_up] $d[phone_for_validation] $d[presign_status] $d[ip_address] $d[browser_string]
CLEAR EMAIL - SIGNATURE FOUND"; }elseif(isset($_GET['php_session_id']) && empty($_GET['follow_up'])){ $php_session_id = $_GET['php_session_id']; echo "

Review $php_session_id

"; $q = "SELECT * FROM presign where php_session_id = '$php_session_id' order by id desc "; $r = $petition->query($q); while($d = mysqli_fetch_array($r)){ $color = 'white'; $test = date('Y-m-d',strtotime($d['action_on'])); $pos = strpos($test, date('Y-m-d')); if ($pos !== false) { $color= 'yellow'; } echo ""; } echo "
$d[action_on] $d[php_page] ".id2petition($d['petition'])." $d[invite] $d[invite_error] $d[name] $d[email_for_follow_up] $d[phone_for_validation] $d[presign_status] $d[ip_address] $d[browser_string]
CLEAR SESSION - SIGNATURE FOUND
- ADD TO FOLLOW UP LIST Maryland General
- ADD TO FOLLOW UP LIST MGP
- ADD TO FOLLOW UP LIST MLP
- ADD TO FOLLOW UP LIST BTEC
- ADD TO FOLLOW UP LIST PG
- ADD TO FOLLOW UP LIST Ivey "; }elseif(isset($_GET['php_session_id']) && isset($_GET['follow_up'])){ $php_session_id = $_GET['php_session_id']; echo "

Adding Follow up for $php_session_id to $_GET[follow_up]

"; $q = "SELECT * FROM presign where php_session_id = '$php_session_id' order by id desc "; $r = $petition->query($q); while($d = mysqli_fetch_array($r)){ $color = 'white'; $test = date('Y-m-d',strtotime($d['action_on'])); $pos = strpos($test, date('Y-m-d')); if ($pos !== false) { $color= 'yellow'; } if ($d[name] != ''){ $name = $d[name]; } if ($d[email_for_follow_up] != ''){ $email = $d[email_for_follow_up]; } echo ""; } $petition->query("insert into follow_up (name, email, php_session, petition_id, date_sent) values ('$name','$email','$php_session_id','$_GET[follow_up]','".date('Y-m-d')."') "); $petition->query("update presign set presign_status = 'DONE' where php_session_id = '$php_session_id' "); $petition->query("update presign set presign_status = 'DONE' where email_for_follow_up = '$email' "); echo "
$d[action_on] $d[php_page] ".id2petition($d['petition'])." $d[invite] $d[invite_error] $d[name] $d[email_for_follow_up] $d[phone_for_validation] $d[presign_status] $d[ip_address] $d[browser_string]
"; }elseif (isset($_GET['VTRID'])){ $VTRID = $_GET['VTRID']; $petition_id = $_GET['petition_id']; echo "

Review $VTRID

"; $q = "SELECT * FROM signatures where VTRID = '$VTRID' and signature_status = 'verified' and petition_id = '$petition_id' order by petition_id, id DESC "; $r = $petition->query($q); $i=0; while($d = mysqli_fetch_array($r)){ $color = 'white'; $pos = strpos($d['date_time_signed'], date('Y-m-d')); if ($pos !== false) { $color= 'yellow'; } echo ""; if ($i == 0){ js_redirect("analytics.php?flag_duplicate=$d[id]"); } $i++; } echo "
$d[date_time_signed] $d[ip_address] ".id2petition($d['petition_id'])." $d[signed_name_as] $d[signed_name_as_circulator] $d[contact_phone] $d[printed_status] flag invalid signature flag VTRID flag ip address flag duplicate contact phone resign requested bot
"; die(); } ?>

Signature Analytics - Server Clock:

NEVER NEVER NEVER CALL OR TEXT ANYONE - ONLY EMAIL!!!

SysOp Says: Transparency = Trust

IP Address
Watching for duplicates.
    query($q); while($d = mysqli_fetch_array($r)){ if ($d['count'] > 1){ echo "
  1. $d[ip_address] ".id2petition($d['petition_id'])." $d[count] $d[signed_name_as]
  2. "; } } ?>
*/ ?>

VTRID

Watching for duplicates.
    query($q); $i=0; while($d = mysqli_fetch_array($r)){ if ($d['count'] > 1){ echo "
  1. $d[VTRID] ".id2petition($d['petition_id'])." $d[count] $d[signed_name_as]
  2. "; if ($i == 0){ js_redirect("analytics.php?VTRID=$d[VTRID]&petition_id=$d[petition_id]"); } $i++; } } ?>

Pre-Sign

Follow up requested - never signed.
'' order by id $order"; $r = $petition->query($q); while($d = mysqli_fetch_array($r)){ $q2="SELECT * FROM presign where php_session_id = '$d[php_session_id]' order by id desc"; $r2 = $petition->query($q2); $d2 = mysqli_fetch_array($r2); $sig = ''; if ($d2['name'] != ''){ $q3 = "SELECT date_time_signed FROM signatures where signed_name_as = '$d2[name]'"; $r3 = $petition->query($q3); $d3 = mysqli_fetch_array($r3); if ($d3['date_time_signed'] != ''){ $sig = "SIGNATURE $d3[date_time_signed]
"; js_redirect("analytics.php?sign_email=$d2[email_for_follow_up]"); } } $presig=''; $q4="SELECT * FROM presign where email_for_follow_up = '$d2[email_for_follow_up]' and php_page like '/sign.php%'"; $r4 = $petition->query($q4); $d4 = mysqli_fetch_array($r4); if ($d4['action_on']){ $presig = "PRESIG $d4[action_on]
"; js_redirect("analytics.php?sign_email=$d2[email_for_follow_up]"); } $invite_error=''; $q4="SELECT * FROM presign where email_for_follow_up = '$d2[email_for_follow_up]' and invite_error <> '' "; $r4 = $petition->query($q4); $d4 = mysqli_fetch_array($r4); if ($d4['invite_error'] != ''){ $invite_error = "$d4[invite_error]
"; js_redirect("analytics.php?clear_email=$d2[email_for_follow_up]"); } $php_session_id = $d2['php_session_id']; echo ""; if( $presig == '' && $invite_error == '' && $sig == '' ){ if ($d2['invite'] == 'Ivey'){ js_redirect("analytics.php?php_session_id=$php_session_id&follow_up=8"); die(); } if ($d2['invite'] == 'mlp'){ js_redirect("analytics.php?php_session_id=$php_session_id&follow_up=2"); die(); } if ($d2['invite'] == 'BTEC'){ js_redirect("analytics.php?php_session_id=$php_session_id&follow_up=3"); die(); } if ($d2['invite'] == 'RestorePGTermLimits'){ js_redirect("analytics.php?php_session_id=$php_session_id&follow_up=7"); die(); } if (id2petition($d2['petition']) == 'RESTORE TWO TERM (8 YEAR) TERM LIMITS IN PRINCE GEORGE'){ js_redirect("analytics.php?php_session_id=$php_session_id&follow_up=7"); die(); } if ($d2['invite'] == 'mgp'){ js_redirect("analytics.php?php_session_id=$php_session_id&follow_up=1"); die(); } js_redirect("analytics.php?php_session_id=$php_session_id&follow_up=X"); // no invite found no petition found - send general follow/up } } ?>
$d2[action_on]$presig $sig $invite_error $d2[name]$d2[email_for_follow_up] ".id2petition($d2['petition'])."$d2[invite] General - MGP - MLP - BTEC - PG - Ivey

Signatures

Last 10
    query($q); while($d = mysqli_fetch_array($r)){ echo "
  1. $d[date_time_signed] ".id2petition($d['petition_id'])." $d[signed_name_as]
  2. "; } ?>

VTRID Bugs

Watching for 0
    'bot' and signature_status <> 'flag_invalid_signature' and signature_status <> 'resign_requested'"; $r = $petition->query($q); while($d = mysqli_fetch_array($r)){ echo "
  1. $d[date_time_signed] $d[ip_address] IP INFO $d[petition_id] $d[signed_name_as]
  2. "; } ?>

Petition ID Bugs

Watching for 0
    'bot' and signature_status <> 'flag_invalid_signature' and signature_status <> 'resign_requested'"; $r = $petition->query($q); while($d = mysqli_fetch_array($r)){ echo "
  1. $d[date_time_signed] $d[ip_address] IP INFO $d[petition_id] $d[signed_name_as]
  2. "; } ?>

resign_requested

These are most likely from early bugs
    query($q); $show = 0; while($d = mysqli_fetch_array($r)){ $show = 1; echo "
  1. $d[date_time_signed] $d[ip_address] IP INFO $d[VTRID] $d[petition_id] $d[signed_name_as]
  2. "; } ?>

bots

These are bots on the site.
    query($q); $show = 0; while($d = mysqli_fetch_array($r)){ $show = 1; echo "
  1. $d[date_time_signed] $d[ip_address] IP INFO $d[VTRID] $d[petition_id] $d[signed_name_as]
  2. "; } ?>