GithubHelp home page GithubHelp logo

beardedlinuxgeek / awesome-charts Goto Github PK

View Code? Open in Web Editor NEW

This project forked from jyusan/awesome-charts

0.0 2.0 0.0 1.59 MB

PHP and JQuery solution for visualizing Awesomenauts character stats.

PHP 6.32% CSS 0.30% JavaScript 93.38%

awesome-charts's Introduction

awesome-charts

Web solution for visualizing Awesomenauts character stats. Uses PHP (5.2+), MySQL, JQuery, HTML5, CSS and Javascript. The MySQL database stores the top 5000 ranked users' character preferences.

Setup

  1. Not included in the repo: config folder needs to include
  2. a .connection.php script with variables storing the MySQL connection configuration (for what's needed check db.php) and
  3. a .key.php file for the admin key needed ($admin_key) for some admin features.
  4. The folder db_scripts contains the SQL scripts for initializing the MySQL tables.
  5. To save historic data for finished seasons run init.php?key=ADMIN_KEY. If the script runs too long, adjust the loop.
  6. Make sure update_current.php?key=ADMIN_KEY is called so that the current leaderboard's data is loaded as well.

Data update

To keep data up-to-date, there are to scripts that can be called in automated cron jobs:

  • update_current.php fetches the data of the current season. Usual runtime on my test server is a few seconds, can be run every 5 minutes or so.
  • update_historic.php script checks whether the last finished season's historic data has been saved. Should run after the end of every season, or on the first day of every month (not sure when the leaderboard switch happens, timing needs to depend on that)

Other notable scripts

  • db.php stores the DB singleton object that does all the MySQL data access
  • data_functions.php has all the convenience functions
  • *chart.php scripts are for displaying the charts and some raw statistics.

Credits

awesome-charts's People

Contributors

jyusan avatar

Watchers

James Cloos avatar Colin avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.