Jump to content

[BF4] Stats webpage for XpKiller's Stats Logger Plugin


tyger07

Recommended Posts

Originally Posted by CptChaos*:

 

I think the query used explains it all:

 

SELECT `MapName`, COUNT(`MapName`) AS number FROM `tbl_mapstats` WHERE `ServerID` = 3 GROUP BY `MapName`;

 

Making it global is also easy, just remove the WHERE-clause.

 

Results are passed to pChart (it just needs the mapnames and numbers) and pChart does the rest.

It requires some extra files in the class folder though.

 

I'll see what I can do to make the pie larger, I think it would help a lot.

Thing is, with the expansions coming, the image would become higher in height as well, because the legend on the left could become taller, depending on serversettings.

* Restored post. It could be that the author is no longer active.
Link to comment
  • Replies 1.7k
  • Created
  • Last Reply

Originally Posted by ty_ger07*:

 

Love the work, thanks!

 

It would be awesome if you could also make something similar to this for each server to be able to use on our home pages.

What kind of information would you want displayed? The exact same information you linked to or something else?
* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by Jamesonp*:

 

What kind of information would you want displayed? The exact same information you linked to or something else?

The exact info (minus the ranking of course) would be great. Clicking a player displays their stats.
* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by ty_ger07*:

 

The exact info (minus the ranking of course) would be great. Clicking a player displays their stats.

I am confused why it is even necessary if the information is the same. It seems like the one would be equal to the other other than the name linking to their stats page.

 

I will consider it.

 

You would have to include it into your page as an iframe the same way as you do with the GameTracker iframe if you wanted the stylesheet to work properly since I am not sure how to make a PHP page compile itself as an image (maybe it isn't too difficult though, I don't know). You would use query strings I suppose to control what information is or isn't shown just like you do with the GameTracker server information.

* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by ty_ger07*:

 

iframes would be ok. The only reason I'm asking for it is so users can easily click on players in game and get their statistics.

Good idea!

 

Compiling it as an image wouldn't work in that case because you can't click links in images, so it would have to be an iframe.

* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by ty_ger07*:

 

Hey Hey!

 

I haven't compiled a PHP image before, so I started with that first. It's coming along nicely. The iframe version just didn't seem like much of a challenge. But don't worry, once I make an image version, adding the same as an iframe version will be easy since the code will be mostly reused.

* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by ty_ger07*:

 

Code linked to in first post has been updated!

 

Changes:

- Minor bug fix with counting sessions on the index page and global stats pages

- Added server banner generator for generating server banners for website homepage

 

See Banner Example to see what it looks like and how to use it:

http://open-web-community.com/bf4sta...r/example.html

 

The issue with displaying it as an image is that the data will tend to be outdated because user's browsers will cache the image and display the image as a cached image. But displaying it as an iframe should work great and should be what all of you are used to doing with GameTracker server banners.

* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by Jamesonp*:

 

Looking good ty_ger! Thanks for the banners. Just a few notes:

 

1) Heads up for people running adblock with easylist - banner.php is automatically blocked (it will cause your banners not to display. Fix this by renaming banner.php to serverbanner.php)

 

 

2) Is it possible to change the size of the "Online Players" box height?

* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by ty_ger07*:

 

Currently it shows about 10 players, lets say I want it to show 20 players.  What would I need to change?
For one thing, you increased your font size, so I can't give an exact number of pixels if I don't know what font size you are going to use.

The height of the DIV is here:
Code:
<div class="section"><b>Online Players:</b></div>
<div style="height: 184px; overflow-y: auto; overflow-x: hidden;">
Change height from 184px to what you want.  But then of course you will need to increase your iframe height as well otherwise data will spill off the bottom.

I will upload a new version soon with font size increased from 11px to 12px, current players increased from 10 players to 20 players, and a couple other tiny improvements.
* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by Jamesonp*:

 

For one thing, you increased your font size, so I can't give an exact number of pixels if I don't know what font size you are going to use.

The height of the DIV is here:
Code:
<div class="section"><b>Online Players:</b></div>
<div style="height: 184px; overflow-y: auto; overflow-x: hidden;">
Change height from 184px to what you want.  But then of course you will need to increase your iframe height as well otherwise data will spill off the bottom.

I will upload a new version soon with font size increased from 11px to 12px, current players increased from 10 players to 20 players, and a couple other tiny improvements.
Thanks I figured it out.  I appreciate all the help and your time!
* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by ty_ger07*:

 

Code in first post updated!

 

Changes:

- server banner iframes now shows 20 current players in server instead of 10

- server banner iframe has sql injection threat fix added

- server banner php file name changed to prevent popup blocking

- server banner minor text and formatting changes

* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by Kinsman*:

 

You know, know that you have mastered drawing php images, the next logical extension would be Player and Server Signatures. :ohmy:

 

http://www.junglewraiths.net/index.php_name=bf4stats

 

Click on a player to get their popup, then click on signatures.

 

BTW can you make players online a variable, or tell me how to make it ten again, theres no way I can use Iframes that long.

 

No matter, I figured it out.

 

http://www.junglewraiths.net/index.p...=Content&pid=3

 

Online and Top 10 should prob both be options, for maximum versatility.

* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by BoneHead1211*:

 

First of all : Nice Work @ ty_ger07

i have made some modifications to show the weapongraphs :smile:

Sure it is a cosmetic but it looks nice if you can see the weapon as a picture. Some weapons i have to fix in its name but almost ready ...

You can see it here : http://www.battlefield4you.de/bf4sta...ID=40&search=1

* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by ty_ger07*:

 

Code linked to in first post updated:

 

Changes:

- More server banner generator help in example file and an additional option to adjust online player count shown in server banner.

 

For example of changes, see example file:

http://open-web-community.com/bf4sta...r/example.html

 

Note that the fourth example shows how suggested iframe sizes are now given to make your life easier.

* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by ty_ger07*:

 

You know, know that you have mastered drawing php images, the next logical extension would be Player and Server Signatures. :ohmy:

I am not so sure most forums allow you to insert a PHP file in as an image in BBcode. I guess it depends on whether the BBcode searches to see that it does provide an image header with dimensions. If it doesn't look, it will see that it is a PHP file and not even try.

 

Test:

http://open-web-community.com/bf4stats/player-stats/banner/serverbanner.php_ServerID=3

 

EDIT:

I guess this vBulletin must support it at least.

 

EDIT2:

It seems ASPPlayground also supports inserting the PHP generated image.

 

I am not sure about phpBB though yet.

 

EDIT3:

The start of a pretty bland (so far) signature image generator:

http://open-web-community.com/bf4stats/player-stats/signature/signature.php_PlayerID=1540

 

http://open-web-community.com/bf4stats/player-stats/signature/signature.php_PlayerID=2

 

Any ideas for better colors?

* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by ty_ger07*:

 

First of all : Nice Work @ ty_ger07

i have made some modifications to show the weapongraphs :smile:

Sure it is a cosmetic but it looks nice if you can see the weapon as a picture. Some weapons i have to fix in its name but almost ready ...

You can see it here : http://www.battlefield4you.de/bf4sta...ID=40&search=1

It looks real good. Finding all the weapon images and updating them each expansion pack is what scares me.
* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by Kinsman*:

 

Correct, thats why the files need to be named .png just like EzStats and gametracker do it.

 

Download EzStats here to see how it works.

 

http://sourceforge.net/projects/ezstats3/

 

and here is my sig from EzStats.

 

Posted Image

 

I cant see any reason our own stats cant generate the same?

* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by ty_ger07*:

 

Correct, thats why the files need to be named .png just like EzStats and gametracker do it.

 

Download EzStats here to see how it works.

 

http://sourceforge.net/projects/ezstats3/

 

and here is my sig from EzStats.

 

Posted Image

 

I cant see any reason our own stats cant generate the same?

Because a .png file isn't executable as PHP. It needs to be named .PHP to execute as PHP. Creating a cache of a bunch of .png images -- one for each user -- seems like an inefficient way to proceed.

 

As you can see above, .PHP is embedding fine as an image.

 

Have you tried embedding this image in your forum to see if it works?

 

http://open-web-community.com/bf4sta..._PlayerID=1540

 

It embeds fine here.

 

http://open-web-community.com/bf4stats/player-stats/signature/signature.php_PlayerID=1540

 

I just tried it on phpBB and it works fine in phpBB.

 

http://www.try-phpbb.com/30x/viewtop...f=2&t=1&p=2#p2

 

So, it works on vBulletin, on ASPplayground, and on phpBB. Those are the most popular forums I can think of.

* Restored post. It could be that the author is no longer active.
Link to comment

Archived

This topic is now archived and is closed to further replies.




  • Our picks

    • Game Server Hosting:

      We're happy to announce that EZRCON will branch out into the game server provider scene. This is a big step for us so please having patience if something doesn't go right in this area. Now, what makes us different compared to other providers? Well, we're going with the idea of having a scaleable server hosting and providing more control in how you set up your server. For example, in Minecraft, you have the ability to control how many CPU cores you wish your server to have access to, how much RAM you want to use, how much disk space you want to use. This type of control can't be offered in a single service package so you're able to configure a custom package the way you want it.

      You can see all the available games here. Currently, we have the following games available.

      Valheim (From $1.50 USD)


      Rust (From $3.20 USD)


      Minecraft (Basic) (From $4.00 USD)


      Call of Duty 4X (From $7.00 USD)


      OpenTTD (From $4.00 USD)


      Squad (From $9.00 USD)


      Insurgency: Sandstorm (From $6.40 USD)


      Changes to US-East:

      Starting in January 2022, we will be moving to a different provider that has better support, better infrastructure, and better connectivity. We've noticed that the connection/routes to this location are not ideal and it's been hard getting support to correct this. Our contract for our two servers ends in March/April respectively. If you currently have servers in this location you will be migrated over to the new provider. We'll have more details when the time comes closer to January. The new location for this change will be based out of Atlanta, GA. If you have any questions/concerns please open a ticket and we'll do our best to answer them.
      • 5 replies
    • Hello All,

      I wanted to give an update to how EZRCON is doing. As of today we have 56 active customers using the services offered. I'm glad its doing so well and it hasn't been 1 year yet. To those that have services with EZRCON, I hope the service is doing well and if not please let us know so that we can improve it where possible. We've done quite a few changes behind the scenes to improve the performance hopefully. 

      We'll be launching a new location for hosting procon layers in either Los Angeles, USA or Chicago, IL. Still being decided on where the placement should be but these two locations are not set in stone yet. We would like to get feedback on where we should have a new location for hosting the Procon Layers, which you can do by replying to this topic. A poll will be created where people can vote on which location they would like to see.

      We're also looking for some suggestions on what else you would like to see for hosting provider options. So please let us know your thoughts on this matter.
      • 4 replies
    • Added ability to disable the new API check for player country info


      Updated GeoIP database file


      Removed usage sending stats


      Added EZRCON ad banner



      If you are upgrading then you may need to add these two lines to your existing installation in the file procon.cfg. To enable these options just change False to True.

      procon.private.options.UseGeoIpFileOnly False
      procon.private.options.BlockRssFeedNews False



       
      • 2 replies
    • I wanted I let you know that I am starting to build out the foundation for the hosting services that I talked about here. The pricing model I was originally going for wasn't going to be suitable for how I want to build it. So instead I decided to offer each service as it's own product instead of a package deal. In the future, hopefully, I will be able to do this and offer discounts to those that choose it.

      Here is how the pricing is laid out for each service as well as information about each. This is as of 7/12/2020.

      Single MySQL database (up to 30 GB) is $10 USD per month.



      If you go over the 30 GB usage for the database then each additional gigabyte is charged at $0.10 USD each billing cycle. If you're under 30GB you don't need to worry about this.


      Databases are replicated across 3 zones (regions) for redundancy. One (1) on the east coast of the USA, One (1) in Frankfurt, and One (1) in Singapore. Depending on the demand, this would grow to more regions.


      Databases will also be backed up daily and retained for 7 days.




      Procon Layer will be $2 USD per month.


      Each layer will only allow one (1) game server connection. The reason behind this is for performance.


      Each layer will also come with all available plugins installed by default. This is to help facilitate faster deployments and get you up and running quickly.


      Each layer will automatically restart if Procon crashes. 


      Each layer will also automatically restart daily at midnight to make sure it stays in tip-top shape.


      Custom plugins can be installed by submitting a support ticket.




      Battlefield Admin Control Panel (BFACP) will be $5 USD per month


      As I am still working on building version 3 of the software, I will be installing the last version I did. Once I complete version 3 it will automatically be upgraded for you.





      All these services will be managed by me so you don't have to worry about the technical side of things to get up and going.

      If you would like to see how much it would cost for the services, I made a calculator that you can use. It can be found here https://ezrcon.com/calculator.html

       
      • 11 replies
    • I have pushed out a new minor release which updates the geodata pull (flags in the playerlisting). This should be way more accurate now. As always, please let me know if any problems show up.

       
      • 9 replies
×
×
  • Create New...

Important Information

Please review our Terms of Use and Privacy Policy. We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.