Home >Backend Development >PHP Tutorial >Examples of generating line charts, pie charts, and bar charts in PHP

Examples of generating line charts, pie charts, and bar charts in PHP

WBOY
WBOYOriginal
2016-07-25 08:55:281009browse

  1. < ;?
  2. $dataArray="";
  3. $nameArray="";
  4. $dataArray = "10,20,30,40,50";
  5. $nameArray = "January, February, March, April, Friday month";
  6. echo "<script>getdata_and_name1('".$dataArray."','".$nameArray."');</script>";
  7. ?>
  8. $dataArray="";
  9. $nameArray="";
  10. $dataArray = "10,20,30,40,50, 20,30,40,50,20,30,40,50";
  11. $nameArray = "January, February, March, April, May, February, March, April, May, February month, March, April, May";
  12. echo "<script>getdata_and_name3('".$dataArray."','".$nameArray."');</script>";
  13. ?> ;
  14. $dataArray="2008,12,12,1,5,7,24,40, 10,25,45,16,19";
  15. $nameArray="January, February, March, April, May, June, July, August, September, October, November, 12 Month";
  16. echo "<script>getdata_and_name2('".$dataArray."','".$nameArray."');</script>";
  17. ?>
Copy code


Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn