Jump to content


  • Posts

  • Joined

  • Last visited

  • Days Won


UOTS-Owner last won the day on March 18 2020

UOTS-Owner had the most liked content!

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

UOTS-Owner's Achievements


Newbie (1/14)



  1. Perfect thank you 🙂
  2. Hello all I am looking to change from md5 to has, I have changed on the register page but I'm not sure what to change my login verification part to it said to use password_verify but I am stuck any idea what to replace my current one to? Thanks $error = ""; $back = "&gt; <a href = 'login.php'><font color = 'red'>Back</font></a>"; $_POST['pass'] = htmlentities(stripslashes($_POST['pass'])); $_POST['username'] = htmlentities(stripslashes($_POST['username'])); if(!$_POST['username'] || !$_POST['pass']) { $error = "<table width = '390px' align = 'center' class = 'table' style = 'padding:5px; margin-top:87px; border-radius:5px;'> <tr> <td align = 'center'><font color = 'red'><b>Please go back and fill in the form correctly<br>".$back; } else { $sql = "SELECT `usr_id`,`usr_fed` FROM `usr_tbl` WHERE `usr_login` = '".mysql_real_escape_string($_POST['username'])."' AND `usr_pas` = '".mysql_real_escape_string(md5($_POST['pass']))."' LIMIT 1"; $sql = mysql_query($sql); if(!mysql_num_rows($sql)) { $error = "<table width = '390px' align = 'center' class = 'table' style = 'padding:5px; margin-top:87px; border-radius:5px;'> <tr> <td align = 'center'><font color = 'red'><b>User not found! Please go back and try again.<br>".$back; } else { $user = mysql_fetch_array($sql); unset($_SESSION['feduser']); if($user['usr_fed'] > time()) { $_SESSION['feduser'] = $user['usr_id']; header('location:fedjail.php'); exit; } else { if($user['usr_fed']) { $sql = "UPDATE `usr_tbl` SET `usr_fed` = '0' WHERE `usr_id` = '".mysql_real_escape_string($user['usr_id'])."'"; mysql_query($sql); } } $_SESSION['myid'] = $user['usr_id']; $_SESSION['verified'] = 0; $sql = "UPDATE `usr_tbl` SET `usr_last_login` = '".mysql_real_escape_string(time())."', `usr_lastact` = '".mysql_real_escape_string(time())."' WHERE `usr_id` = '".mysql_real_escape_string($_SESSION['myid'])."'"; mysql_query($sql);
  3. Could I get an example please to work off say for replacing the original one? SELECT `usr_id`,SUBSTRING_INDEX(usr_stat,':',6) AS offences FROM `usr_tbl` ORDER BY `offences` DESC LIMIT 25
  4. Yeah this is in here but I dont know how to select it https://ibb.co/P5gJFGp
  5. Anyone know how to select a certain value in this field? For instance the 6th one in which shows as 1 https://ibb.co/wzTtxKG This is the current setup but it just selects the first number every time. SELECT `usr_id`,SUBSTRING_INDEX(usr_stat,':',6) AS offences FROM `usr_tbl` ORDER BY `offences` DESC LIMIT 25
  6. Still looking for help on this one.
  7. Yeah still same problem, title adds fine but comment still inserts the same https://ibb.co/YXNXx0F
  8. Title is inserting fine but comment does not.
  9. Now when i post something it inserts but the the msg section always comes up as "You must enter a comment to post"
  10. ok this is my current one tried a few things so it's probably a bit of a mess again right now $_GET['id'] = preg_replace('/[^0-9]/', '', $_GET['id']); $_GET['a'] = preg_replace('/[^a-z]/', '', $_GET['a']); $_POST['msg'] = strip_tags(stripslashes($_POST['msg'])); $_POST['title'] = strip_tags(stripslashes($_POST['title'])); echo "<p_title>New topic</p_title> <hr>"; if(!$_GET['id']) { echo warn("Error, Invalid forum ID!"); } else { $sql = "SELECT * FROM `forums` WHERE `f_id` = '".mysql_real_escape_string($_GET['id'])."'"; $sql = mysql_query($sql); if(!mysql_num_rows($sql)) { echo warn("Error, Invalid forum ID!"); } else { $f = mysql_fetch_array($sql); if($f['f_donly'] == 'yes' && !$user['usr_dondays']) { echo warn("This is a donators only forums!"); } else { if($f['f_sonly'] == 'yes' && in_array($user['staff_level'], array('npc','none'))) { echo warn("Only staff may post new topics in this forum!"); } else { if (!$_POST['msg'] || !$_POST['title']) { $title = null; $msg = null; if (!$_POST['msg']) { $title = "<font color = 'red'><b>Title cannot be blank</b></font>"; } if (!$_POST['title']) { $msg = "<font color = 'red'><b>You must enter a comment to post</b></font>"; } echo "<form name = 'reply' id = 'reply'> <table class = 'table-blue' width = '475px'> <tr> <td align = 'left' width = '300px'> <b>Title:</b> ".$title."<br> <input type = 'text' name = 'title' id = 'title' value = '".$_POST['title']."'><br> <b>Text:</b> ".$msg."<br> <script src='/editor/ckeditor/ckeditor.js'></script> <textarea name='msg' id='editor1' rows='10' cols='80' style='z-index:-100;'></textarea> <script style='z-index:-100;'> // Replace the <textarea id='editor1'> with a CKEditor // instance, using default configuration. CKEDITOR.replace( 'editor1' ); </script> </td> </tr> <tr> <td align = 'left'> <button class = 'psubm:reply:new-topic.php?id=".$_GET['id']."' id = 'linkage'>Submit</button> </td> </tr> </table> </form>"; }
  11. Yeah the duplicate was already removed.
  12. Still no luck without changing id='editor1' back to id='comment' and losing the text editor
  13. Thanks for the response, I tried both of these but still getting You must enter a comment to post
  • Create New...