• 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!

Error Website Menu

felipemko

New Member
Joined
Mar 2, 2010
Messages
175
Reaction score
3
In my website have a menu with the top guild frager with this tag:

<ul>
<?
foreach($SQL->query('SELECT `g`.`id` AS `id`, `g`.`name` AS `name`,
`g`.`logo_gfx_name` AS `logo`, COUNT(`g`.`name`) as `frags`
FROM `killers` k
LEFT JOIN `player_killers` pk ON `k`.`id` = `pk`.`kill_id`
LEFT JOIN `players` p ON `pk`.`player_id` = `p`.`id`
LEFT JOIN `guild_ranks` gr ON `p`.`rank_id` = `gr`.`id`
LEFT JOIN `guilds` g ON `gr`.`guild_id` = `g`.`id`
WHERE `k`.`unjustified` = 1 AND `k`.`final_hit` = 1
GROUP BY `name`
ORDER BY `frags` DESC, `name` ASC
LIMIT 0, 5;') as $guild)
echo '<li><a href="?subtopic=guilds&action=show&guild=' . $guild['id'] . '">' . $guild['name'] . '&nbsp;&nbsp;&nbsp;(' . $guild['frags'] . ' kills)</a></li>';
?>
</ul>
But, dont work, and show this error in the menu:

query('SELECT `g`.`id` AS `id`, `g`.`name` AS `name`, `g`.`logo_gfx_name` AS `logo`, COUNT(`g`.`name`) as `frags` FROM `killers` k LEFT JOIN `player_killers` pk ON `k`.`id` = `pk`.`kill_id` LEFT JOIN `players` p ON `pk`.`player_id` = `p`.`id` LEFT JOIN `guild_ranks` gr ON `p`.`rank_id` = `gr`.`id` LEFT JOIN `guilds` g ON `gr`.`guild_id` = `g`.`id` WHERE `k`.`unjustified` = 1 AND `k`.`final_hit` = 1 GROUP BY `name` ORDER BY `frags` DESC, `name` ASC LIMIT 0, 5;') as $guild) echo '
' . $guild['name'] . ' (' . $guild['frags'] . ' kills)
'; ?>
 
In my website have a menu with the top guild frager with this tag:


But, dont work, and show this error in the menu:

The script uses short PHP tags, so you need to enable it in your server. Or just use:

Code:
<ul>
<?php
foreach($SQL->query('SELECT `g`.`id` AS `id`, `g`.`name` AS `name`,
`g`.`logo_gfx_name` AS `logo`, COUNT(`g`.`name`) as `frags`
FROM `killers` k
LEFT JOIN `player_killers` pk ON `k`.`id` = `pk`.`kill_id`
LEFT JOIN `players` p ON `pk`.`player_id` = `p`.`id`
LEFT JOIN `guild_ranks` gr ON `p`.`rank_id` = `gr`.`id`
LEFT JOIN `guilds` g ON `gr`.`guild_id` = `g`.`id`
WHERE `k`.`unjustified` = 1 AND `k`.`final_hit` = 1
GROUP BY `name`
ORDER BY `frags` DESC, `name` ASC
LIMIT 0, 5;') as $guild)
echo '<li><a href="?subtopic=guilds&action=show&guild=' . $guild['id'] . '">' . $guild['name'] . '&nbsp;&nbsp;&nbsp;(' . $guild['frags'] . ' kills)</a></li>';
?>
</ul>
 
Now no have more erros, but 0 guilds, but its because is a new server, no have guilds, so I think are ok now, rep+ thanks

You can help me one more ? My website dont are accept accents too, why? example: "Doação já" are buged = "doação jĂ"
 
Last edited by a moderator:
Thank you again! The last question, why my website dont work the tag "<blink>?" My browser its ok, because I see in others servers the words using <blink>
 
Look this site of one server, he use <blink> I think... https://www.gunzodus.net/
He uses in the menus

I used this script in my layout.php now, for create <blink> and sucessful...
If anybody see this and wants:
<script type="text/javascript">
function blink() {
var blinks = document.getElementsByTagName('blink');
for (var i = blinks.length - 1; i >= 0; i--) {
var s = blinks;
s.style.visibility = (s.style.visibility === 'visible') ? 'hidden' : 'visible';
}
window.setTimeout(blink, 200);
}
if (document.addEventListener) document.addEventListener("DOMContentLoaded", blink, false);
else if (window.addEventListener) window.addEventListener("load", blink, false);
else if (window.attachEvent) window.attachEvent("onload", blink);
else window.onload = blink;
</script>
 
Last edited by a moderator:
Look this site of one server, he use <blink> I think... https://www.gunzodus.net/
He uses in the menus

No hes not using <blink> tag for that, hes using:

Code:
<script type="text/javascript" >
    function blink(selector){
        $(selector).fadeOut('slow', function(){
            $(this).fadeIn('slow', function(){
                blink(this);
            });
        });
    }
    blink('.msg');
</script>
 
But, how i use t
HTML:
<div class="msg">Message to blink</div>
his? what is tag?

You first need this JavaScript function:

Code:
<script type="text/javascript" >
    function blink(selector){
        $(selector).fadeOut('slow', function(){
            $(this).fadeIn('slow', function(){
                blink(this);
            });
        });
    }
    blink('.msg');
</script>

Then you can use in html:
HTML:
<div class="msg">Message to blink</div>
 
Dont work =/

Works just fine to me, be sure to put the div BEFORE the JavaScript function.. Like:

Code:
<div class="msg">Message to blink</div>

<script type="text/javascript" >
    function blink(selector){
        $(selector).fadeOut('slow', function(){
            $(this).fadeIn('slow', function(){
                blink(this);
            });
        });
    }
    blink('.msg');
</script>
 
Dont have other tag to use this? because div jump line, and i I'm using in text

And here dont work yet... I used div before script
 
Last edited by a moderator:
Back
Top