Hi there, my problem is that the hall of fame of my web is only reading the "M"(Male Folder) so when is a girl char is showing the male gif and not the female has well.
Can someone help me to fix please? this is the code Ty!
else {
$sex = "<img src='".$this->themePath('img/potm/M/0.gif')."' alt=\"Sex\"/>";
$sqlpvp = "SELECT pvpladder.name AS char_name, pvpladder.kills AS kills, pvpladder.deaths AS deaths, pvpladder.streaks, char.char_id, char.class AS bclass, login.sex, guild.name as gname
FROM pvpladder
LEFT JOIN `char` ON pvpladder.char_id = char.char_id
LEFT JOIN `login` ON char.account_id = login.account_id
LEFT JOIN `guild` ON char.guild_id = guild.guild_id
ORDER BY kills DESC
LIMIT 1";
$sthpvp = $server->connection->getStatement($sqlpvp);
$sthpvp->execute();
$hofchars = $sthpvp->fetchAll();
if (empty($hofchars[0]->sex)) {
$bsex = $hofchars[0]->sex;
$bclass = $hofchars[0]->bclass;
$sex = "<img src='".$this->themePath('./img/potm/'.$bsex.'/'.$bclass.'.gif')."' alt=\"Sex\"/>";
} else {
$bsex = array();
$bclass = array();
}
Question
Helly
Hi there, my problem is that the hall of fame of my web is only reading the "M"(Male Folder) so when is a girl char is showing the male gif and not the female has well.
Can someone help me to fix please? this is the code Ty!
Edited by HellyLink to comment
Share on other sites
1 answer to this question
Recommended Posts