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

Dynamic status by Paxton.

At the top of the document, man think a bit ok?

Sorry dude, I just wake up and im tired, Im not good at Php at all.

But still it does not work i putted
Code:
~
varloginStatus=0; loginStatus='false';var activeSubmenuItem='latestnews'; var IMAGES=0; IMAGES='http://roxxor1337.hopto.org/layouts/tibiacom/images'; var LINK_ACCOUNT=0; LINK_ACCOUNT='http://roxxor1337.hopto.org';</script> <link href="layouts/tibiacom/basic.css" rel="stylesheet" type="text/css"> 
<script type="text/javascript" src="layouts/tibiacom/jquery.js"></script>
jquery.js's top
 
Put this:

<script type="text/javascript" src="layouts/tibiacom/jquery.js"></script>


At the top of file!!!

Man, this is not PHP, you put <script> tag into another <script> tag. :|
 
Put this:

<script type="text/javascript" src="layouts/tibiacom/jquery.js"></script>


At the top of file!!!

Man, this is not PHP, you put <script> tag into another <script> tag. :|

Sorry for taking your time etc, and you are getting angry cuz im "noobish" on this. Well, still it does not work i copied and pasted
Code:
<script type="text/javascript" src="layouts/tibiacom/jquery.js"></script>
In Htdocks/layout/tibiacom/jquery.js
And yes at the top!;)
 
Sorry for taking your time etc, and you are getting angry cuz im "noobish" on this. Well, still it does not work i copied and pasted
Code:
<script type="text/javascript" src="layouts/tibiacom/jquery.js"></script>
In Htdocks/layout/tibiacom/jquery.js
And yes at the top!;)

No its not <_<

Im getting agry a bit man, I'm looking at ur source and nothing changed.

Just use your brain alright?
 
At the top of the document, man think a bit ok?
:D :D :D :D :D :D
Its al about ots here... noone is thinking about anything here! I think they even dont know the "search" function, only the "New Threat"-Button.

I realy like your scripts.

Baba
Virgel
 
Doesn't work for me =/. It always shows:



SOLVED, works!

I had the same problem try use that on players.php

PHP:
<?
$config_ini = parse_ini_file('../config/config.ini');
$server_config = parse_ini_file($config_ini['server_path'].'config.lua');
if(isset($_POST['action'])){
$mysqlhost = $server_config['mysqlHost'];
$mysqluser = $server_config['mysqlUser'];
$mysqlpass = $server_config['mysqlPass'];
$mysqldatabase = $server_config['mysqlDatabase'];
mysql_connect($mysqlhost, $mysqluser, $mysqlpass);
mysql_select_db($mysqldatabase);
$sql = mysql_query("SELECT * FROM `players` WHERE `online` = '1'");
$amount = mysql_num_rows($sql);
echo $amount; }
else
echo "Error";
?>
 
This is cool but it's too taxing on your server... People can max out your SQL connections really easy this way and maybe SQL injection.
 
Can someone tell me where to put the
Code:
echo '<div id="players" style="display: inline;">Loading...</div><br>Players Online';
PHP:
   <?PHP
            if($config['status']['serverStatus_online'] == 1)
            echo '
                      <span class="online"><center><font color="green"Server is Online</center></span>
                        <b><font size="3"><a href="?subtopic=whoisonline&world=0">Players Online:</a></font></b> 
						<p>'.$config['status']['serverStatus_players'].' / '.$config['status']['serverStatus_playersMax'].'</p>
                        <b>Uptime:</b> '.$config['status']['serverStatus_uptime'].'
                        <b>Monsters:</b> '.$config['status']['serverStatus_monsters'].'</font>
            ';
            else
            echo '<span class="offline"><font color="red">Server is Offline</font></span>';
          ?>
 
PHP:
$sql = mysql_query("SELECT count(*) FROM `players` WHERE `online` = '1'");
$row = mysql_fetch_row($sql);
echo $row[0];

I think its faster, and dont load sql server so much.
 
Dont use it, it may cause problems with phpmyadmin connections.
# Error 2062 or something like that.
 
It takes 10-30ms anyway so there won't be any big difference.

Also I think I'll add some sessions because people may spam by FireBug they just change 1000 to 1 and it will flood a bit. <_<

Anyway, it's safe and will not cause any lags.
 
Back
Top