Results 501 to 510 of 1641
-
26-01-2014, 14:11 #501
- Join Date
- Nov 2011
- Posts
- 3,053
-
26-01-2014, 14:22 #502
Hi there!
This little mod will change stats webpage by adding map graphics on server background and BF3 BL style buttons. You can view example at http://cnpc.org.pl/stats/index.php.
All you have to do is download archive http://cnpc.org.pl/stats/upgradeV2.rar and extract it to your root folder of stats web page.
If You want to put changes manually
Files to edit:
root/common/displayservers.php
root/common/stats.css
EDIT:
root/common/displayservers.php
FIND:
Code:echo ' <tr> <td width="100%" style="text-align: left;"> <br/> <div class="shadowcontent"> <table width="95%" align="center" border="0"> <tr> <td width="35%"> <br/><a href="' . $_SERVER['PHP_SELF'] . '?ServerID=' . $this_ServerID . '"><font size="3">' . $ServerName . '</font></a><br/><br/> </td> <td width="22%"> <br/><br/><font class="information">Current Players In Server:</font> ' . $players . '<br/><br/> </td> <td width="22%"> <br/><br/><font class="information">Current Map:</font> ' . $map_name . '<br/><br/> </td> <td width="21%"> <br/><br/><font class="information">Users Viewing Stats:</font> ' . $sessions . '<br/><br/> </td> </tr> <tr> <td width="35%"> <a href="' . $_SERVER['PHP_SELF'] . '?ServerID=' . $this_ServerID . '"><img src="./images/viewstatsbtn.png" alt="view stats" class="imagebutton" /></a> <a href="http://battlelog.battlefield.com/bf4/servers/pc/?filtered=1&expand=0&useAdvanced=1&q=' . urlencode($ServerName) . '" target="_blank"><img src="./images/joinbtn.png" alt="join" class="imagebutton" /></a><br/><br/> </td> <td width="22%"> <font class="information">Players Logged:</font> ' . $total_players . '<br/><br/><br/> </td> <td width="22%"> <font class="information">Total Score:</font> ' . $score . '<br/><br/><br/> </td> <td width="21%"> <font class="information">Total Kills:</font> ' . $kills . '<br/><br/><br/> </td> </tr> </table> </div> </td> </tr> ';
Code:echo ' <tr> <td width="100%" style="text-align: left; padding-left: 25px; padding-right: 25px;"> <br/> <div style="background-position: left center; background-repeat: repeat; background-size: 100% auto; border-radius: 10px; box-shadow: 2px 2px 20px 2px rgba(0,0,0,0.5); background-image: url(./images/maps/' . $CurrentMap_r['mapName'] . '.png)"> <div class="shadowcontent"> <table width="95%" align="center" border="0"> <tr> <td width="35%"> <br/><a href="' . $_SERVER['PHP_SELF'] . '?ServerID=' . $this_ServerID . '" style="color: white !important;"><font size="3">' . str_replace('[OPBC] ', '', $ServerName) . '</font></a><br/><br/> </td> <td width="22%"> <br/><br/><div class="bloczek"><font class="information">Current Players In Server:</font> <span style="font-weight: 700;">' . $players . '</span></div><br/><br/> </td> <td width="22%"> <br/><br/><div class="bloczek"><font class="information">Current Map:</font> <span style="font-weight: 700;">' . $map_name . '</span></div><br/><br/> </td> <td width="21%"> <br/><br/><div class="bloczek"><font class="information">Users Viewing Stats:</font> <span style="font-weight: 700;">' . $sessions . '</span></div><br/><br/> </td> </tr> <tr> <td width="35%"> <a href="' . $_SERVER['PHP_SELF'] . '?ServerID=' . $this_ServerID . '"><img src="./images/view-stats.png" alt="" /></a> <a href="http://battlelog.battlefield.com/bf4/pl/servers/pc/?filtered=1&expand=0&useAdvanced=1&q=' . urlencode($ServerName) . '" target="_blank"><img src="./images/join-server.png" alt="" /></a><br/><br/> </td> <td width="22%"> <div class="bloczek"><font class="information">Players Logged:</font> <span style="font-weight: 700;">' . $total_players . '</span></div><br/><br/><br/> </td> <td width="22%"> <div class="bloczek"><font class="information">Total Score:</font> <span style="font-weight: 700;">' . $score . '</span></div><br/><br/><br/> </td> <td width="21%"> <div class="bloczek"><font class="information">Total Kills:</font> <span style="font-weight: 700;">' . $kills . '</span></div><br/><br/><br/> </td> </tr> </table> </div> </div> </td> </tr> ';
root/common/stats.css
AT THE END OF FILE ADD:
Code:.bloczek { padding: 5px; background: none repeat scroll 0% 0% rgba(0, 0, 0, 0.7); float: left; border-radius: 5px; }
Refresh and enjoy!
-
26-01-2014, 15:17 #503
- Join Date
- Nov 2011
- Posts
- 3,053
I had it appear that way previously but removed it. I personally think it is not attractive and does not agree with the rest of the page's style.
BTW, for the background image, you might want to do:
if(in_array($CurrentMap_r['mapName'],$map_array))
{
...
}
To verify that a DLC hasn't just released and make sure that non-existent resources aren't attempted to be loaded.Last edited by ty_ger07; 26-01-2014 at 15:22.
-
26-01-2014, 22:16 #504
THNX!
I personally like it like this, that is why I posted.
-
27-01-2014, 21:20 #505
- Join Date
- Oct 2013
- Posts
- 166
-
28-01-2014, 00:59 #506
- Join Date
- Nov 2011
- Posts
- 3,053
-
29-01-2014, 02:49 #507
i have the chat logger working now, now im trying to get stats web page to work. hopefully this can be solve like the other.
http://www.iba-gaming.com/bf4stats/
// DATABASE INFORMATION
DEFINE('HOST', ''); localhost or IP that data base is on i tried both // database host address
DEFINE('PORT', '3306'); // database port - default is 3306
DEFINE('NAME', 'bf4stats'); // database name
DEFINE('USER', 'xxxxxxx'); // database user name
DEFINE('PASS', 'xxxxxxx'); // database password
-
29-01-2014, 03:57 #508
- Join Date
- Nov 2011
- Posts
- 3,053
Since you are storing the database on your computer, your computer has to be accessible from the internet in order for your website to connect to your computer's database.
'localhost' and '127.0.0.1' will not work. You would need to know what IP address your ISP has given you and your IP address would have to never change. Also, your home network would have to be configured to allow internet traffic in.
It's really a huge security risk to turn your computer into a web server and allow anyone over the internet to connect to your computer. You shouldn't do it unless you know what you are doing (which I don't).
-
04-02-2014, 19:37 #509
- Join Date
- Oct 2011
- Posts
- 98
Latest pull on github breaks the graphs. I updated the pchart library and everything works again.
http://www.pchart.net/download
-
04-02-2014, 22:17 #510
- Join Date
- Feb 2014
- Posts
- 3
The new Weapons won't be in my Webstats log.... Procon read it out of the BF4.def and added it to the DB - but there is no killcount for them. example the ASVal.
Anyone else this problem?
What should i do?