• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

ERROR IN WEBSITE HELP PLEASE ;'C

Auriaotbr

New Member
Joined
Feb 15, 2017
Messages
61
Reaction score
1
Hello everybode, i' have so much errors in my web help me please :C




Warning: Invalid argument supplied for foreach() in C:\xampp\htdocs\pages\patentescores.php on line 62




Warning: date() [function.date]: It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'America/Sao_Paulo' for '-2.0/DST' instead in C:\xampp\htdocs\pages\characters.php on line 65

Warning: date() [function.date]: It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'America/Sao_Paulo' for '-2.0/DST' instead in C:\xampp\htdocs\pages\characters.php on line 69

Warning: Invalid argument supplied for foreach() in C:\xampp\htdocs\pages\characters.php on line 91

Warning: date() [function.date]: It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'America/Sao_Paulo' for '-2.0/DST' instead in C:\xampp\htdocs\pages\characters.php on line 170

Warning: date() [function.date]: It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'America/Sao_Paulo' for '-2.0/DST' instead in C:\xampp\htdocs\pages\characters.php on line 243

Warning: date() [function.date]: It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'America/Sao_Paulo' for '-2.0/DST' instead in C:\xampp\htdocs\pages\characters.php on line 243

Warning: date() [function.date]: It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'America/Sao_Paulo' for '-2.0/DST' instead in C:\xampp\htdocs\pages\characters.php on line 243

Warning: Invalid argument supplied for foreach() in C:\xampp\htdocs\pages\characters.php on line 284




PATENTESCORE LINE 62 - foreach($result as $infoPatente) {

CHARACTERS LINE 65 - $main_content .= '<tr bgcolor="' . $bgcolor . '"><td>Last login:</td><td>' . (($player->getLastLogin() > 0) ? date("j F Y, g:i a", $player->getLastLogin()) : 'Never logged in.') . '</td></tr>';


CHARACTERS LINE 69 - $main_content .= '<tr bgcolor="' . $bgcolor . '"><td>Created:</td><td>' . date("j F Y, g:i a", $player->getCreateDate()) . '</td></tr>';


CHARACTERS LINE 91 - foreach ($list as $number_of_items_showed => $slot)

CHARACTERS LINE 170 - $dead_add_content .= "<tr bgcolor=\"".$bgcolor."\"><td width=\"20%\" align=\"center\">".date("j M Y, H:i", $death['date'])."</td><td>";


CHARACTERS LINE 243 3 ERRORS '-' - <td width=\"20%\" align=\"center\">".date("j M Y, H:i", $frag['date'])."</td>

CHARACTERS LINE 284 - foreach ($tasks as $task) {



HELP-ME PLEASE !

 
For the error relating to your timezone, you must manually set your preferred timezone.
PHP:
date_default_timezone_set('America/Sao_Paulo');

As for the other errors, you must first check that the variables that you're looping through actually contains an iterable response.
PHP:
if (is_array($result)) {
   // foreach here
}

Or if that's beyond your reach, you may try to simply cast the variable into an array and see if that helps.
PHP:
foreach ((array) $result as $infoPatente)
 
For the error relating to your timezone, you must manually set your preferred timezone.
PHP:
date_default_timezone_set('America/Sao_Paulo');

As for the other errors, you must first check that the variables that you're looping through actually contains an iterable response.
PHP:
if (is_array($result)) {
   // foreach here
}

Or if that's beyond your reach, you may try to simply cast the variable into an array and see if that helps.
PHP:
foreach ((array) $result as $infoPatente)


Please give-me PHP codes for resolvid :c
 
Back
Top