PHP Classes

File: uploady/admin/assets/demo/chart-bar-demo.js

Recommend this page to a friend!
  Classes of Faris AL-Otabi   Uploady PHP Upload File to MySQL   uploady/admin/assets/demo/chart-bar-demo.js   Download  
File: uploady/admin/assets/demo/chart-bar-demo.js
Role: Auxiliary data
Content type: text/plain
Description: Auxiliary data
Class: Uploady PHP Upload File to MySQL
Store file upload details in a MySQL database
Author: By
Last change: Update of uploady/admin/assets/demo/chart-bar-demo.js
Date: 4 months ago
Size: 1,614 bytes
 

Contents

Class file image Download
// Set new default font family and font color to mimic Bootstrap's default styling Chart.defaults.global.defaultFontFamily = '-apple-system,system-ui,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif'; Chart.defaults.global.defaultFontColor = "#292b2c"; $(document).ready(function () { $.post("logic/barChart.php", function (data) { var install_date = []; var numbers_of_clients = []; for (var i in data) { install_date.push(data[i].label); numbers_of_clients.push(data[i].data); } // Bar Chart Example var ctx = document.getElementById("myBarChart"); var myLineChart = new Chart(ctx, { type: "bar", data: { labels: install_date, datasets: [ { label: "Files", backgroundColor: "rgba(2,117,216,1)", borderColor: "rgba(2,117,216,1)", data: numbers_of_clients, }, ], }, options: { scales: { xAxes: [ { time: { unit: "Month", }, gridLines: { display: true, }, ticks: { maxTicksLimit: 10, }, }, ], yAxes: [ { ticks: { min: 0, max: 16, maxTicksLimit: 32, }, gridLines: { display: true, }, }, ], }, legend: { display: false, }, }, }); }); });