if (!$sessionid) { //echo 'Error processing url. Because of a database error at the start of the age about 50 people received an invalid activation url. A new mail was dispatched to their e-mail address with instructions on how to fix the problem.<br>'; echo 'Invalid url!<br>'; $no = 1; } else { $sql = "SELECT id, name FROM {$db_register_accounts} WHERE session_id = '{$sessionid}' AND status = '98'"; $result = $db->query($sql); $numrows = $db->num_rows($result); if ($numrows != 1) { echo 'You have already activated your account.<br>'; $no = 1; } else { $row = $db->fetch_array($result); } } if ($no == 0) { $id = $row["id"]; $time = time(); $sql = "UPDATE {$db_register_accounts} SET session_id = '0', status = '0', time = '{$time}' WHERE id = '{$id}'"; $result = $db->query($sql); gTutorial($id, $gdFirstTutorialId); echo ' Your account has been activated successfully.<br> Go to <a href="indexnl.php?page=nl_home&name=', $row["name"], '">this page</a> to log in. '; } else { die; } } else { die("<br>You haven't completed the previous registration step yet."); }
<?php if ($page == "news" && $action == "nexttutorial" && $tid) { $nid = gTutorial($acc["id"], $tid); $acc["newscache"] = ""; } if ($page != "news" || $page == "news" && $nid) { if ($acc["newscache"] == "") { $ntext = ""; $sql = "SELECT id, topic, time, type FROM news WHERE (news.range = '0' AND target = '{$acc['id']}') OR (news.range = '1' AND target = '{$acc['kingdom']}') OR news.range = '2' ORDER BY time DESC LIMIT 0,5"; $result = $db->query($sql); $numrows = $db->num_rows($result); if ($numrows == 0) { $ntext .= 'No news yet.'; } else { $ntext .= '<table width="100%" border="0" cellspacing="0" cellpadding="0">'; while ($row = $db->fetch_array($result)) { if ($row["topic"] == "READ THIS RIGHT NOW OR YOUR ACCOUNT WILL BE KILLED") { $row["topic"] = "<font color=\"#FF0000\">" . $row["topic"] . "</font>"; } $date = date("Y-m-d", $row["time"]); $ntext .= ' <tr> <td width="2%"> </td> <td width="19%" align="left"> ' . $date . ' </td> <td width="79%" align="left"> <a href="index.php?page=news&nid=' . $row["id"] . '">' . $gdNewsTypes[$row["type"]] . ': ' . stripslashes($row["topic"]) . '</a> </td>