checkin ... die infos der attacken werden nun nicht mehr nach id gemacht ... sprich neue fruechte koennen nun eingepflegt werden ... die kategorisierung geht nach wochen_markt.kategorie
@ -182,16 +182,12 @@ function showAtks($linkz,$tf='',$rassen='',$order='',$type='',$pagenum='',$fruch
} elseif ($type == 'db') {
$attacken = mysql_query("SELECT * FROM attacken WHERE (rassen LIKE '%2,%' OR rassen LIKE '%3,%' OR rassen LIKE '%4,%' OR rassen LIKE '%5,%' OR rassen LIKE '%6,%' OR rassen LIKE '%7,%' OR rassen LIKE '%10,%') AND Frucht is NULL AND rassen!='11,' AND info not like '%npc attacke%' $order ".' LIMIT '.($pagenum * 20).', 20 ');
} elseif ($type == 'tf') {
if ($fruchttyp == 'paramecia') {
$attacken = mysql_query("SELECT * FROM attacken WHERE (Frucht=3 OR Frucht=4 OR Frucht=9 OR Frucht=11 OR Frucht=12 OR Frucht=38 OR Frucht=14 OR Frucht=17 OR Frucht=26 OR Frucht=2 OR Frucht=19 OR Frucht=20 OR Frucht=21 OR Frucht=22) AND info not like '%npc attacke%' $order ".' LIMIT '.($pagenum * 20).', 20 ');
} elseif ($fruchttyp == 'zoan') {
$attacken = mysql_query("SELECT * FROM attacken WHERE (Frucht=31 OR Frucht=30 OR Frucht=33 OR Frucht=34 OR Frucht=35 OR Frucht=32 OR Frucht=29 OR Frucht=16) AND info not like '%npc attacke%' $order ".' LIMIT '.($pagenum * 20).', 20 ');
} elseif ($fruchttyp == 'logia') {
$attacken = mysql_query("SELECT * FROM attacken WHERE (Frucht=23 OR Frucht=24 OR Frucht=8 OR Frucht=15 OR Frucht=6) AND info not like '%npc attacke%' $order ".' LIMIT '.($pagenum * 20).', 20 ');
} else {
$attacken = mysql_query("SELECT * FROM attacken WHERE Frucht!=0 AND rassen!='11,' AND info not like '%npc attacke%' $order ".' LIMIT '.($pagenum * 20).', 20 ');
}
} else {
$condition = getFruchtCondition($fruchttyp);
// select attacken.*, wochen_markt.kategorie from attacken inner join wochen_markt on attacken.frucht = wochen_markt.id
$sql = 'SELECT attacken.* FROM attacken inner join wochen_markt on attacken.frucht = wochen_markt.id WHERE ' .$condition.' attacken.info not like \'%npc attacke%\' '.$order.' LIMIT '.($pagenum * 20).', 20 ';
$attacken = mysql_query($sql);
} else {
$attacken = mysql_query("SELECT * FROM attacken WHERE info NOT LIKE '%npc attacke%' $order ".' LIMIT '.($pagenum * 20).', 20 ');
}
} else {
@ -237,15 +233,8 @@ function showAtks($linkz,$tf='',$rassen='',$order='',$type='',$pagenum='',$fruch
} elseif ($type == 'db') {
$total = mysql_num_rows(mysql_query("SELECT id FROM attacken WHERE (rassen LIKE '%2,%' OR rassen LIKE '%3,%' OR rassen LIKE '%4,%' OR rassen LIKE '%5,%' OR rassen LIKE '%6,%' OR rassen LIKE '%7,%' OR rassen LIKE '%10,%') AND Frucht is NULL AND rassen!='11,' AND info not like '%npc attacke%' "));
} elseif ($type == 'tf') {
if ($fruchttyp == 'paramecia') {
$total = mysql_num_rows(mysql_query("SELECT id FROM attacken WHERE (Frucht=3 OR Frucht=4 OR Frucht=9 OR Frucht=11 OR Frucht=12 OR Frucht=38 OR Frucht=14 OR Frucht=17 OR Frucht=26 OR Frucht=2 OR Frucht=19 OR Frucht=20 OR Frucht=21 OR Frucht=22) AND info not like '%npc attacke%' "));
} elseif ($fruchttyp == 'zoan') {
$total = mysql_num_rows(mysql_query("SELECT id FROM attacken WHERE (Frucht=31 OR Frucht=30 OR Frucht=33 OR Frucht=34 OR Frucht=35 OR Frucht=32 OR Frucht=29 OR Frucht=16) AND info not like '%npc attacke%' "));
} elseif ($fruchttyp == 'logia') {
$total = mysql_num_rows(mysql_query("SELECT id FROM attacken WHERE (Frucht=23 OR Frucht=24 OR Frucht=8 OR Frucht=15 OR Frucht=6) AND info not like '%npc attacke%' "));
} else {
$total = mysql_num_rows(mysql_query("SELECT id FROM attacken WHERE Frucht!=0 AND rassen!='11,' AND info not like '%npc attacke%' "));
}
$condition = getFruchtCondition($fruchttyp);
$total = mysql_num_rows(mysql_query('SELECT attacken.* FROM attacken inner join wochen_markt on attacken.frucht = wochen_markt.id WHERE ' .$condition.' attacken.info not like \'%npc attacke%\''));
} else {
$total = mysql_num_rows(mysql_query("SELECT id FROM attacken WHERE info NOT LIKE '%npc attacke%' "));
}
@ -348,34 +337,44 @@ function atksHeaderRasse($type,$link,$fruchttyp) {
$tf_query= mysql_query('SELECT * FROM wochen_markt WHERE (id!=25 AND id!=41 AND id!=42) AND (id=4 OR id=11 OR id=9 OR id=14 OR id=20 OR id=3 OR id=12 OR id=38 OR id=17 OR id=26 OR id=2 OR id=19 OR id=21 OR id=22 OR id=409 OR id=410 OR id=411 OR id=412) ORDER BY item ASC');
$tf_query= mysql_query('SELECT * FROM wochen_markt WHERE (id!=25 AND id!=41 AND id!=42) AND (id=29 OR id=31 OR id=34 OR id=35 OR id=30 OR id=33 OR id=16 OR id=32 OR id=401 OR id=403 OR id=405 OR id=407) ORDER BY item ASC');
$tf_query= mysql_query('SELECT * FROM wochen_markt WHERE (id!=25 AND id!=41 AND id!=42) AND (id=8 OR id=23 OR id=24 OR id=6 OR id=15 OR id=413 OR id=414) ORDER BY item ASC');