So basically i'm getting this error,
Any idea's of what's gone wrong here?
This is the line of code,
Quote:if(!modcp_can_manage_user($user['uid']))
Can anyone help?
which version of MyBB exactly you are using ?
run file verification tool available at tools & maintenance section of admin panel to find missing / changed files.
ignore files reported from install folder & its subfolders. you have to replace reported files from MyBB source
files pack of your forum's version.
I'm running 1.8.3. and this is the errror i got.
So just reupload that folder?
this is the code inside of the folder.
Quote:
- <?php
- /**
- * MyBB 1.8
- * Copyright 2014 MyBB Group, All Rights Reserved
- *
- * Website: http://www.mybb.com
- * License: http://www.mybb.com/about/license
- *
- */
-
- function find_warnlevels_to_check(&$query, &$max_expiration_times, &$check_levels)
- {
- global $db;
-
- // we have some warning levels we need to revoke
- $max_expiration_times = array(
- 1 => -1, // Ban
- 2 => -1, // Revoke posting
- 3 => -1 // Moderate posting
- );
- $check_levels = array(
- 1 => false, // Ban
- 2 => false, // Revoke posting
- 3 => false // Moderate posting
- );
- while($warn_level = $db->fetch_array($query))
- {
- // revoke actions taken at this warning level
- $action = my_unserialize($warn_level['action']);
- if($action['type'] < 1 || $action['type'] > 3) // prevent any freak-ish cases
- {
- continue;
- }
-
- $check_levels[$action['type']] = true;
-
- $max_exp_time = &$max_expiration_times[$action['type']];
- if($action['length'] && $max_exp_time != 0)
- {
- $expiration = $action['length'];
- if($expiration > $max_exp_time)
- {
- $max_exp_time = $expiration;
- }
- }
- else
- {
- $max_exp_time = 0;
- }
- }
- }
-
- /**
- * Returns a friendly expiration time of a suspension/warning
- *
- * @param int The time period of the suspension/warning
- * @return array An array of the time/period remaining
- */
- function fetch_friendly_expiration($time)
- {
- if($time == 0 || $time == -1)
- {
- return array("period" => "never");
- }
- else if($time % 2592000 == 0)
- {
- return array("time" => $time/2592000, "period" => "months");
- }
- else if($time % 604800 == 0)
- {
- return array("time" => $time/604800, "period" => "weeks");
- }
- else if($time % 86400 == 0)
- {
- return array("time" => $time/86400, "period" => "days");
- }
- else
- {
- return array("time" => ceil($time/3600), "period" => "hours");
- }
- }
-
- /**
- * Figures out the length of a suspension/warning
- *
- * @param int The amount of time to calculate the length of suspension/warning
- * @param string The period of time to calculate the length of suspension/warning
- * @return int Length of the suspension/warning (in seconds)
- */
- [b]function fetch_time_length($time, $period)[/b]
- {
- $time = (int)$time;
-
- if($period == "hours")
- {
- $time = $time*3600;
- }
- else if($period == "days")
- {
- $time = $time*86400;
- }
- else if($period == "weeks")
- {
- $time = $time*604800;
- }
- else if($period == "months")
- {
- $time = $time*2592000;
- }
- else if($period == "never" && $time == 0)
- {
- // User is permanentely banned
- $time = "-1";
- }
- else
- {
- $time = 0;
- }
- return $time;
- }
-
Nevermind, fixed it thanks for your help .m.!