Commit | Line | Data |
---|---|---|
ce4bc703 | 1 | <?PHP |
01c4bf16 | 2 | include_once('header.php'); |
71c5b49d | 3 | setcookie("invite", "RestorePGTermLimits", time()+3600, "/"); // we use this later |
ce4bc703 PM |
4 | ?> |
5 | <!DOCTYPE html> | |
6 | <html lang="en"> | |
7 | <head> | |
8 | <!-- Global site tag (gtag.js) - Google Analytics --> | |
9 | <script async src="https://www.googletagmanager.com/gtag/js?id=UA-165887820-1"></script> | |
10 | <script> | |
11 | window.dataLayer = window.dataLayer || []; | |
12 | function gtag(){dataLayer.push(arguments);} | |
13 | gtag('js', new Date()); | |
14 | ||
15 | gtag('config', 'UA-165887820-1'); | |
16 | </script> | |
17 | <?PHP | |
18 | include_once('/var/www/secure.php'); //outside webserver | |
01c4bf16 | 19 | presign(); // requires db connection |
ce4bc703 PM |
20 | $q = "select * from petitions where petition_id = '7'"; |
21 | $r = $petition->query($q); | |
22 | $d = mysqli_fetch_array($r); | |
23 | include_once('../slack.php'); | |
24 | ?> | |
eef754a2 | 25 | <meta property="og:url" content="https://www.md-petition.com/invite/RestorePGTermLimits.php" /> |
ce4bc703 PM |
26 | <meta property="og:type" content="website" /> |
27 | <meta property="og:title" content="<?PHP echo $d['tab_name'];?>" /> | |
28 | <meta property="og:description" content="Maryland Electronic Petition Software - Socially Distant Petitions" /> | |
f4f8c478 | 29 | <meta property="og:image" content="https://www.md-petition.com/files/RTL.png" /> |
ce4bc703 PM |
30 | <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.4.1/css/bootstrap.min.css"> |
31 | <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.4.1/jquery.min.js"></script> | |
32 | <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.4.1/js/bootstrap.min.js"></script> | |
33 | <title><?PHP echo $d['tab_name'];?></title> | |
34 | </head> | |
35 | <body style='background-color:<?PHP echo $d['web_color'];?>;'> | |
36 | <div class="container-fluid"> | |
37 | <?PHP | |
38 | slack_general('RestorePGTermLimits Home Page Loaded ('.$_COOKIE['invite'].')','md-petition'); | |
39 | ?> | |
40 | ||
41 | <div class='row'> | |
42 | <div class='col-sm-10' style='text-align:center;'><h1><?PHP echo $d['text_title'];?></h1><h2 style='text-align:left;'><?PHP echo $d['text_block'];?></h2></div> | |
43 | </div> | |
44 | <div class='row'> | |
45 | <div class='col-sm-10' style='text-align:center;'><button type="button" class="btn btn-success btn-lg btn-block" onclick="window.location.href='../enter_information.php'">SIGN <?PHP echo $d['petition_name'];?></button></div> | |
46 | </div> | |
47 | ||
48 | <div class='row'> | |
49 | <div class='col-sm-10' style='text-align:center;'> <img class="img-responsive" alt="<?PHP echo $d['text_title'];?>" src="<?PHP echo $d['logo_url'];?>"></div> | |
50 | </div> | |
51 | ||
52 | <div id="fb-root"></div> | |
53 | <script>(function(d, s, id) { | |
54 | var js, fjs = d.getElementsByTagName(s)[0]; | |
55 | if (d.getElementById(id)) return; | |
56 | js = d.createElement(s); js.id = id; | |
57 | js.src = "https://connect.facebook.net/en_US/sdk.js#xfbml=1&version=v3.0"; | |
58 | fjs.parentNode.insertBefore(js, fjs); | |
59 | }(document, 'script', 'facebook-jssdk'));</script> | |
60 | ||
61 | <script> | |
62 | function myFunction(short_code) { | |
63 | /* Get the text field */ | |
64 | var copyText = document.getElementById(short_code); | |
65 | ||
66 | /* Select the text field */ | |
67 | copyText.select(); | |
68 | copyText.setSelectionRange(0, 99999); /*For mobile devices*/ | |
69 | ||
70 | /* Copy the text inside the text field */ | |
71 | document.execCommand("copy"); | |
72 | ||
73 | /* Alert the copied text */ | |
74 | alert("Copied the Link: " + copyText.value); | |
75 | } | |
76 | </script> | |
77 | ||
78 | <center> | |
79 | <table border="1" cellpadding="2" cellspacing="0"> | |
80 | <tr> | |
d10bea05 PM |
81 | <td><div class="fb-share-button" |
82 | data-href="http://md-petition.com/invite/RestorePGTermLimits.php" | |
83 | data-layout="box_count" data-size="large"> | |
ce4bc703 PM |
84 | </div></td> |
85 | <td><input type='text' size='50' value='http://md-petition.com/invite/RestorePGTermLimits.php' id='mgp'><button onclick='myFunction("RestorePGTermLimits")'>Copy Link</button></td> | |
86 | </tr> | |
87 | </table> | |
88 | </center> | |
89 | ||
90 | ||
91 | ||
92 | <?PHP | |
93 | $copy = '© 2020 Patrick McGuire'; | |
94 | ?> | |
95 | <div class='row'> | |
96 | <div class='col-sm-10' style='text-align:center;'><?PHP echo $copy;?></div> | |
97 | </div> | |
98 | ||
99 | <div class='row'> | |
100 | <div class='col-sm-10' style='text-align:center;'> | |
101 | <?PHP if($_COOKIE['debug'] == 'on'){ ?> | |
102 | <pre><?PHP print_r($_GET); ?></pre> | |
103 | <pre><?PHP print_r($_POST); ?></pre> | |
104 | <pre><?PHP print_r($_COOKIE); ?></pre> | |
105 | <?PHP } ?> | |
106 | </div> | |
107 | </div> |