boss record (respawn fail)

01/30/2019 01:24 jenny2011#1
Deutsch:

Guten morgen freunde.

Ich habe das aktuelle Boss Record script auf meiner HomePage eingeflegt.
Und ich wollte es gerne wie auf den Bild haben.

---->[Only registered and activated users can see links. Click Here To Register...]

Jedoch sieht meins so aus, wo die Pfeile sind.

---->[Only registered and activated users can see links. Click Here To Register...]

Und das ist ein Teil des Scriptes wo die Respawnzeit steht.
Was müßte ich ändern, um es wie auf den ersten Bild aussehen zu lassen?

---->[Only registered and activated users can see links. Click Here To Register...]

Bitte kann mir da einer weiter helfen?

beste grüße. :-)

----------------------------------------------------------

English

Good morning friends.

I have inserted the current Boss Record script on my HomePage.
And I wanted to have it like in the picture.

---->[Only registered and activated users can see links. Click Here To Register...]

However, mine looks like where the arrows are.

---->[Only registered and activated users can see links. Click Here To Register...]

And that's part of the script where the respawn time is.
What would I have to change to make it look like the first picture?

---->[Only registered and activated users can see links. Click Here To Register...]

Please can one help me further?

best regards. :-)

((((((( sorry for my english :-/ ))))
01/30/2019 02:18 [GameAdvisor]Finn#2
Quote:
Originally Posted by jenny2011 View Post
Deutsch:

Guten morgen freunde.

Ich habe das aktuelle Boss Record script auf meiner HomePage eingeflegt.
Und ich wollte es gerne wie auf den Bild haben.

---->[Only registered and activated users can see links. Click Here To Register...]

Jedoch sieht meins so aus, wo die Pfeile sind.

---->[Only registered and activated users can see links. Click Here To Register...]

Und das ist ein Teil des Scriptes wo die Respawnzeit steht.
Was müßte ich ändern, um es wie auf den ersten Bild aussehen zu lassen?

---->[Only registered and activated users can see links. Click Here To Register...]

Bitte kann mir da einer weiter helfen?

beste grüße. :-)

----------------------------------------------------------

English

Good morning friends.

I have inserted the current Boss Record script on my HomePage.
And I wanted to have it like in the picture.

---->[Only registered and activated users can see links. Click Here To Register...]

However, mine looks like where the arrows are.

---->[Only registered and activated users can see links. Click Here To Register...]

And that's part of the script where the respawn time is.
What would I have to change to make it look like the first picture?

---->[Only registered and activated users can see links. Click Here To Register...]

Please can one help me further?

best regards. :-)

((((((( sorry for my english :-/ ))))
this is 2H is text only
Gallery
find hour config and change it! or change that 2H to what time boss respawn
01/30/2019 02:41 jenny2011#3
Thanks for your reply.
That it is only text, I thought so.
I've already tried back and forth. But I do not know what I have to enter as a command to display an automatic respawn time.

best regards.
01/30/2019 09:12 beetols#4
you need to use javascript and php.

Create a second page called bosses.php where you insert bosses table and got the death time and [Only registered and activated users can see links. Click Here To Register...].

Now in your main page need to use [Only registered and activated users can see links. Click Here To Register...]function where you call bosses.php file every second and load in the div where table actually is.

You will find all what you need by using [Only registered and activated users can see links. Click Here To Register...]!

Suggestion: Create a boss table in PS_GameLog for avoid lags when load.


PS: SubStr() is a varchar function. correct way is [Only registered and activated users can see links. Click Here To Register...]
01/30/2019 20:56 jenny2011#5
they did not understand my post.

I asked how do I get the respawn time back displayed?
I have already done everything else.

greetings
01/31/2019 02:46 [MXD]Takeshi#6
this information not is present in database, so you can create a function in php for get back the hours of boss for example:

Code:
function get_hours($mobid){

switch ($mobid){

case 2081:
     return '2h';
     break;
case 2080:
     return '5h';
     break;

}
}
inside your view:

Code:
echo '<td>'. get_hours($s['Var1') .'</td>'; // atm not remember the right columns name
i think this is what you need.
01/31/2019 04:12 jenny2011#7
Thank you for your answer. :-)
I'll show you the best the php I use.
maybe it can help you get started with it.
best regards

PHP Code:
<meta http-equiv="refresh" content="10">
<html>
<head>
<style type="text/css">
html, body {height:100%; margin:0; padding:0;}
#page-background {position:fixed; top:0; left:0; width:50%; height:50%;}
#content {position:relative; z-index:1; padding:10px;}
body,th {
color: #f0d693;
font-size: 15px;
}
td {
    font-size: 13px;
    color: #f0d693;
}
</style>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body text="#FFFFFF">
<div id="page-background"></div>
<div id="content">
<?php
function mssql_escape_string($data) {
if(!isset(
$data) or empty($data)) return '';
if(
is_numeric($data)) return $data;
$non_displayables = array(
'/%0[0-8bcef]/'// url encoded 00-08, 11, 12, 14, 15
'/%1[0-9a-f]/'// url encoded 16-31
'/[\x00-\x08]/'// 00-08
'/\x0b/'// 11
'/\x0c/'// 12
'/[\x0e-\x1f]/' // 14-31
);
foreach(
$non_displayables as $regex)
$data preg_replace($regex,'',$data);
$data str_replace("'","''",$data);
return 
$data;
}

$host '127.0.0.1';
$dbuser 'NAME'// put here your DB login
$dbpass 'PW'// put here your password DB
$database 'PS_GameLog';
$conn =  [MENTION=311501]ODB[/MENTION]c_connect("Driver={SQL Server};Server=$host;Database=$database"$dbuser$dbpass) or die("Database Connection Error!");
$res odbc_exec($conn"SELECT [ActionTime] FROM [dbo].[Boss_Death_Log] WHERE [MobID]='2793'order by ActionTime desc");
$detail=odbc_fetch_array($res);
$res1 odbc_exec($conn"SELECT [ActionTime] FROM [dbo].[Boss_Death_Log] WHERE [MobID]='964'order by ActionTime desc");
$detail1=odbc_fetch_array($res1);
$res2 odbc_exec($conn"SELECT [ActionTime] FROM [dbo].[Boss_Death_Log] WHERE [MobID]='737'order by ActionTime desc");
$detail2=odbc_fetch_array($res2);
$res3 odbc_exec($conn"SELECT [ActionTime] FROM [dbo].[Boss_Death_Log] WHERE [MobID]='2803'order by ActionTime desc");
$detail3=odbc_fetch_array($res3);
$res4 odbc_exec($conn"SELECT [ActionTime] FROM [dbo].[Boss_Death_Log] WHERE [MobID]='2469'order by ActionTime desc");
$detail4=odbc_fetch_array($res4);
$res5 odbc_exec($conn"SELECT [ActionTime] FROM [dbo].[Boss_Death_Log] WHERE [MobID]='2545'order by ActionTime desc");
$detail5=odbc_fetch_array($res5);
$res6 odbc_exec($conn"SELECT [ActionTime] FROM [dbo].[Boss_Death_Log] WHERE [MobID]='2465'order by ActionTime desc");
$detail6=odbc_fetch_array($res6);
$res7 odbc_exec($conn"SELECT [ActionTime] FROM [dbo].[Boss_Death_Log] WHERE [MobID]='2785'order by ActionTime desc");
$detail7=odbc_fetch_array($res7);
$res8 odbc_exec($conn"SELECT [ActionTime] FROM [dbo].[Boss_Death_Log] WHERE [MobID]='964'order by ActionTime desc");
$detail8=odbc_fetch_array($res8);
$res9 odbc_exec($conn"SELECT [ActionTime] FROM [dbo].[Boss_Death_Log] WHERE [MobID]='964'order by ActionTime desc");
$detail9=odbc_fetch_array($res9);
$s=str_replace("-","/",$detail);
$s1=str_replace("-","/",$detail1);
$s2=str_replace("-","/",$detail2);
$s3=str_replace("-","/",$detail3);
$s4=str_replace("-","/",$detail4);
$s5=str_replace("-","/",$detail5);
$s6=str_replace("-","/",$detail6);
$s7=str_replace("-","/",$detail7);
$s8=str_replace("-","/",$detail8);
$s9=str_replace("-","/",$detail9);
echo 
"
<table cellspacing=1 cellpadding=4 border=1 style=\"border-style:hidden;\">
<tr>
<th>Boss Name</th>
<th>Kill Zeit</th>
<th>Respawn</th>
</tr>"
;
echo 
"<tr>";
echo 
"<td>"'Asiris' ."</td><td>"substr($s['ActionTime'],019) ."</td><td>"'12H' ."</td>";
echo 
"</tr>";
echo 
"<tr>";
echo 
"<td>"'Astaroth' ."</td><td>"substr($s1['ActionTime'],019) ."</td><td>"'12H' ."</td>";
echo 
"</tr>";
echo 
"<tr>";
echo 
"<td>"'Loca' ."</td><td>"substr($s2['ActionTime'],019) ."</td><td>"'2H' ."</td>";
echo 
"</tr>";
echo 
"<tr>";
echo 
"<td>"'Secreta' ."</td><td>"substr($s3['ActionTime'],019) ."</td><td>"'12H' ."</td>";
echo 
"</tr>";
echo 
"<tr>";
echo 
"<td>"'Dios Exiel' ."</td><td>"substr($s4['ActionTime'],019) ."</td><td>"'15H' ."</td>";
echo 
"</tr>";
echo 
"<tr>";
echo 
"<td>"'War Command' ."</td><td>"substr($s5['ActionTime'],019) ."</td><td>"'12H' ."</td>";
echo 
"</tr>";
echo 
"<tr>";
echo 
"<td>"'Huistaton' ."</td><td>"substr($s6['ActionTime'],019) ."</td><td>"'6H' ."</td>";
echo 
"</tr>";
echo 
"<tr>";
echo 
"<td>"'Ales' ."</td><td>"substr($s7['ActionTime'],019) ."</td><td>"'12H' ."</td>";
echo 
"</tr>";
echo 
"<tr>";
echo 
"<td>"'Loca' ."</td><td>"substr($s8['ActionTime'],019) ."</td><td>"'2H' ."</td>";
echo 
"</tr>";
echo 
"<tr>";
echo 
"<td>"'Secreta' ."</td><td>"substr($s9['ActionTime'],019) ."</td><td>"'12H' ."</td>";
echo 
"</tr>";
echo 
"</table>";

?>
01/31/2019 11:20 beetols#8
Quote:
Originally Posted by jenny2011 View Post
they did not understand my post.

I asked how do I get the respawn time back displayed?
I have already done everything else.

greetings
I gave you all the answers you need to complete your boss script. I've only forgot to mention that need to use brain.exe for understand it..

Quote:
<meta http-equiv="refresh" content="10">
<html>
<head>


<!-- Style goes in main page, don't need reload it every second-->
<style type="text/css">
html, body {height:100%; margin:0; padding:0;}
#page-background {position:fixed; top:0; left:0; width:50%; height:50%;}
#content {position:relative; z-index:1; padding:10px;}
body,th {
color: #f0d693;
font-size: 15px;
}
td {
font-size: 13px;
color: #f0d693;
}
</style>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body text="#FFFFFF">
<div id="page-background"></div>
<div id="content">

<?php
function mssql_escape_string($data) {
if(!isset($data) or empty($data)) return '';
if(is_numeric($data)) return $data;
$non_displayables = array(
'/%0[0-8bcef]/', // url encoded 00-08, 11, 12, 14, 15
'/%1[0-9a-f]/', // url encoded 16-31
'/[\x00-\x08]/', // 00-08
'/\x0b/', // 11
'/\x0c/', // 12
'/[\x0e-\x1f]/' // 14-31
);
foreach($non_displayables as $regex)
$data = preg_replace($regex,'',$data);
$data = str_replace("'","''",$data);
return $data;
}

$host = '127.0.0.1';
$dbuser = 'NAME'; // put here your DB login
$dbpass = 'PW'; // put here your password DB
$database = 'PS_GameLog';
$conn = @[Only registered and activated users can see links. Click Here To Register...]c_connect("Driver={SQL Server};Server=$host;Database=$database", $dbuser, $dbpass) or die("Database Connection Error!");
$res = odbc_exec($conn, "SELECT [ActionTime] FROM [dbo].[Boss_Death_Log] WHERE [MobID]='2793'order by ActionTime desc");
$detail=odbc_fetch_array($res);
$res1 = odbc_exec($conn, "SELECT [ActionTime] FROM [dbo].[Boss_Death_Log] WHERE [MobID]='964'order by ActionTime desc");
$detail1=odbc_fetch_array($res1);
$res2 = odbc_exec($conn, "SELECT [ActionTime] FROM [dbo].[Boss_Death_Log] WHERE [MobID]='737'order by ActionTime desc");
$detail2=odbc_fetch_array($res2);
$res3 = odbc_exec($conn, "SELECT [ActionTime] FROM [dbo].[Boss_Death_Log] WHERE [MobID]='2803'order by ActionTime desc");
$detail3=odbc_fetch_array($res3);
$res4 = odbc_exec($conn, "SELECT [ActionTime] FROM [dbo].[Boss_Death_Log] WHERE [MobID]='2469'order by ActionTime desc");
$detail4=odbc_fetch_array($res4);
$res5 = odbc_exec($conn, "SELECT [ActionTime] FROM [dbo].[Boss_Death_Log] WHERE [MobID]='2545'order by ActionTime desc");
$detail5=odbc_fetch_array($res5);
$res6 = odbc_exec($conn, "SELECT [ActionTime] FROM [dbo].[Boss_Death_Log] WHERE [MobID]='2465'order by ActionTime desc");
$detail6=odbc_fetch_array($res6);
$res7 = odbc_exec($conn, "SELECT [ActionTime] FROM [dbo].[Boss_Death_Log] WHERE [MobID]='2785'order by ActionTime desc");
$detail7=odbc_fetch_array($res7);
$res8 = odbc_exec($conn, "SELECT [ActionTime] FROM [dbo].[Boss_Death_Log] WHERE [MobID]='964'order by ActionTime desc");
$detail8=odbc_fetch_array($res8);
$res9 = odbc_exec($conn, "SELECT [ActionTime] FROM [dbo].[Boss_Death_Log] WHERE [MobID]='964'order by ActionTime desc");
$detail9=odbc_fetch_array($res9);
$s=str_replace("-","/",$detail);
$s1=str_replace("-","/",$detail1);
$s2=str_replace("-","/",$detail2);
$s3=str_replace("-","/",$detail3);
$s4=str_replace("-","/",$detail4);
$s5=str_replace("-","/",$detail5);
$s6=str_replace("-","/",$detail6);
$s7=str_replace("-","/",$detail7);
$s8=str_replace("-","/",$detail8);
$s9=str_replace("-","/",$detail9);

$boss1 = date_format($date_create($detail['ActionTime']),"H:i:s", strtotime("+43200"));

//Here need to add an if where you see if the time i expired or not! in case is not expired show the countdown else need to return something like "UP NOW".

echo "
<table cellspacing=1 cellpadding=4 border=1 style=\"border-style:hidden;\">
<tr>
<th>Boss Name</th>
<th>Kill Zeit</th>
<th>Respawn</th>
</tr>";
echo "<tr>";
echo "<td>Asiris</td><td>".date_format($date_create($detail['ActionTime']),"Y/m/d")."</td><td>".$boss1."</td>";
Guess what I used:
- [Only registered and activated users can see links. Click Here To Register...]
- [Only registered and activated users can see links. Click Here To Register...]
Exactly, same urls I added in my first post + brain.exe :p

43200 are the seconds, just typing 12 hours in seconds on google you get it.

About HTML tags I striked, there is to say that you don't need them in a called page, plus you didn't close them on the end, that is a very bad habit.

In code way this make no sense: ". 'string' ."
" //interrupt the string;
. //add php variable;
. //end of adding;
" //Continue string;

I'm sure you can complete it by yourself now..
Quote:
echo "</tr>";
echo "<tr>";
echo "<td>". 'Astaroth' ."</td><td>". substr($s1['ActionTime'],0, 19) ."</td><td>". '12H' ."</td>";
echo "</tr>";
echo "<tr>";
echo "<td>". 'Loca' ."</td><td>". substr($s2['ActionTime'],0, 19) ."</td><td>". '2H' ."</td>";
echo "</tr>";
echo "<tr>";
echo "<td>". 'Secreta' ."</td><td>". substr($s3['ActionTime'],0, 19) ."</td><td>". '12H' ."</td>";
echo "</tr>";
echo "<tr>";
echo "<td>". 'Dios Exiel' ."</td><td>". substr($s4['ActionTime'],0, 19) ."</td><td>". '15H' ."</td>";
echo "</tr>";
echo "<tr>";
echo "<td>". 'War Command' ."</td><td>". substr($s5['ActionTime'],0, 19) ."</td><td>". '12H' ."</td>";
echo "</tr>";
echo "<tr>";
echo "<td>". 'Huistaton' ."</td><td>". substr($s6['ActionTime'],0, 19) ."</td><td>". '6H' ."</td>";
echo "</tr>";
echo "<tr>";
echo "<td>". 'Ales' ."</td><td>". substr($s7['ActionTime'],0, 19) ."</td><td>". '12H' ."</td>";
echo "</tr>";
echo "<tr>";
echo "<td>". 'Loca' ."</td><td>". substr($s8['ActionTime'],0, 19) ."</td><td>". '2H' ."</td>";
echo "</tr>";
echo "<tr>";
echo "<td>". 'Secreta' ."</td><td>". substr($s9['ActionTime'],0, 19) ."</td><td>". '12H' ."</td>";
echo "</tr>";
echo "</table>";
?>
Might be that I'm still not understanding your english, but this is all what you need to make it display as countdown and I hope you understood to use google for find what you need, because it's your best friend!

You are welcome..
02/02/2019 18:13 visionthing10#9
Nettes Script würdest du dieses Realeasen wenn ja pn einfach
04/23/2019 17:51 nicki93#10
how to get prat from full code or full code for boss spwan time i do not understand much and im not "you" with php codding ?