<?
include '/home/mmaaaco/public_html/cjorgensen/dbconnect.php';
$link = base64_decode($_GET['link']);
$upsql =  $dbh->prepare("update users set active = '1' where email   = ?" );
$upsql->bindValue(1,$link);
$upsql->execute();
$checkwork = $dbh->prepare("select active from users where email = ?");
$checkwork->bindValue(1,$link);
$checkwork->execute();
$row = $checkwork->fetch();
$active = $row['active'];
//we only care if we can't activate!
if ($active != 1){
	echo ' there is a problem with your account. please contact us!'; 
exit();
}
header ("Location: login.php?msg=success");
//lets activate !!!


?>


<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>Account activation</title>
</head>

<body>
</body>
</html>
