if (!$_GET["hash"] || !$_GET["email"]) { if (isset($_GET)) { unset($_GET); } $alert = 'Necessary values are incomplete'; } else { // if hash and email are present $GET_hash = htmlspecialchars($_GET["hash"]); $GET_email = htmlspecialchars($_GET["email"]); if (check_email_exist($GET_email) === true && check_email_confirmed($GET_email) === true) { $location = "login.php?action=alreadyconfirmed"; redirect("{$location}"); } elseif (check_email_exist($GET_email) === true && check_email_confirmed($GET_email) === false) { $database_email_hash = get_database_email_hash($GET_email); if ($GET_hash === $database_email_hash) { confirm_email($GET_email); $location = "login.php?action=confirmed"; redirect("{$location}"); } else { if (isset($_GET)) { unset($_GET); } $alert = 'Invalid email or confirmation code'; } // end else } else { if (isset($_GET)) { unset($_GET); } $alert = 'Invalid email or confirmation code'; }
<?php require "settings.php"; if (isset($_POST["key"])) { $OUTPUT = write_remove($_POST); } else { $OUTPUT = confirm_email($_GET); } require "template.php"; function confirm_email($_GET) { extract($_GET); if (!isset($email) or strlen($email) < 1) { return "Invalid Use Of Module. Invalid Email Address."; } db_connect(); #verify if this is a valid email adress $get_check = "SELECT * FROM cubit.email_groups WHERE emailaddress = '{$email}' LIMIT 1"; $run_check = db_exec($get_check) or errDie("Unable to get email address information."); if (pg_numrows($run_check) < 1) { #email address not found ?? return "Email Address Not Found In List."; } $display = "\n\t\t\t\t\t<table " . TMPL_tblDflts . ">\n\t\t\t\t\t<form action='" . SELF . "' method='POST'>\n\t\t\t\t\t\t<input type='hidden' name='key' value='confirm'>\n\t\t\t\t\t\t<input type='hidden' name='email' value='{$email}'>\n\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t<th>Confirm Removal Of This Email Address From Email Groups</th>\n\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t<tr class='" . bg_class() . "'>\n\t\t\t\t\t\t\t<td>{$email}</td>\n\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t" . TBL_BR . "\n\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t<td align='right'><input type='submit' value='Confirm Removal'></td>\n\t\t\t\t\t\t</tr>\n\t\t\t\t\t</form>\n\t\t\t\t\t</table>\n\t\t\t\t"; return $display; } function write_remove($_POST) { extract($_POST); if (!isset($email)) { return "Invalid Use Of Email.";
$output .= ' <h1>' . lang("edit", "edit_your_acc") . '</h1>'; } unset($err); $output .= ' </div>'; $action = isset($_GET["action"]) ? $_GET["action"] : NULL; if ($action == "doedit_user") { doedit_user(); } elseif ($action == "lang_set") { lang_set(); } elseif ($action == "theme_set") { theme_set(); } elseif ($action == "profile_set") { profile_set(); } elseif ($action == "confirm_email") { confirm_email(); } elseif ($action == "cancel_email_change") { cancel_email_change(); } elseif ($action == "send_invite") { send_invite(); } elseif ($action == "delete_invite") { delete_invite(); } elseif ($action == "resend_invite") { send_invite(true); } else { edit_user(); } unset($action); unset($action_permission); require_once "footer.php";
<h2>Your Order:</h2> <hr> <table><tbody><th>Item</th><th>Quantity</th><th>Price</th>' . $out_table . '</div><br><br><br><br> <form name = "purchase" action="index.php?checkout=1&close=1" method="POST"> <input type="text" hidden name="mail" value="1"> <input class="complete_purchase_button" type="submit" value="complete purchase"> </form> </div> <div> <div class="continue_shopping_link"><a href="index.php?close=1">Continue Shopping!</a></div><!-- end .continue_shopping_link --> </div>'; // If the post variable "mail" is set and equals 1, send the confirmation email and display the confirmation message. if (isset($_POST['mail']) && $_POST['mail'] == 1) { $thanks = confirm_email($_SESSION['username']); if ($thanks) { echo $thanks; } if (!$thanks) { echo "There was a problem and we could not send your confirmation email"; } } echo '</body></html>'; } elseif (isset($_GET['remove_cart']) && $_GET['remove_cart'] == 1) { remove_from_cart($_POST); } elseif (!isset($_GET['admin']) && !isset($_GET['order'])) { $product_list = display(); for ($i = 0; $i < count($product_list); $i++) { echo $product_list[$i]; }