• 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!
  • 2026 staff recruitment is open! Check it out and consider applying!

problem in znote's highscore

Imfreezing

Krossa Kapitalismen
Joined
Jun 7, 2012
Messages
1,009
Solutions
1
Reaction score
88
Location
Edron
hey I use @Znote 1.5 web, but the highscores doesn't work
Code:
Notice: Undefined index: in /home/otsmanager/www/public_html/engine/function/general.php on line 328

Notice: Undefined index: in /home/otsmanager/www/public_html/engine/function/general.php on line 328
that's the error
and thats the script
http://pastebin.com/RvS1cDA0
thanks!
 
You need to configure all your vocation IDs that your server use here:
https://github.com/Znote/ZnoteAAC/blob/master/config.php#L257-267

That error appears when you try to fetch vocation name from a player, but it does not find it in the config file.
Or he could just replace

This:
// Vocation ids and names.
$config['vocations'] = array(
0 => 'No vocation',
1 => 'Sorcerer',
2 => 'Druid',
3 => 'Paladin',
4 => 'Knight',
5 => 'Master Sorcerer',
6 => 'Elder Druid',
7 => 'Royal Paladin',
8 => 'Elite Knight',
);

For this:
// change this to your vocations.xml path
$vpath = 'C:\Users\Name\Desktop\theforgottenserv\data\XML\vocations.xml';
$voc = array();
$doNotListTheseVocations = array(0,5,6,7,8);

if(file_exists($vpath) && $xml = simplexml_load_file($vpath)){
foreach($xml as $xmlx){
if(!in_array(intval($xmlx['id']), $doNotListTheseVocations, true)){
if(isset($xmlx['id']) && isset($xmlx['name']) ){
$voc[intval($xmlx['id'])] = (string)$xmlx['name'];
}
}
}
}$config['vocations'] = $voc;
 
Back
Top