Need a unique gift idea?
A Pastebin account makes a great Christmas gift
SHARE
TWEET

Untitled

a guest Jul 12th, 2018 59 Never
Upgrade to PRO!
ENDING IN00days00hours00mins00secs
 
  1. ## count.php
  2. <?php
  3. include('db_connect.inc.php');
  4. include('framework.inc.php');
  5. include('charts.php');
  6. $qry=mysql_query("SELECT string FROM count");
  7. $arr=array();
  8. $chart['chart_type']="pie";
  9. while($row=mysql_fetch_assoc($qry)) {
  10.     $string = $row['string'];
  11.  
  12.    
  13.         $string=trim($string);
  14.         $string=explode(",",$string);
  15.         foreach ($string as $key) {
  16.             if (array_key_exists($key, $arr)) { $arr[$key]++; }
  17.             else { $arr[$key] = 1; }
  18.        
  19.             }
  20.         }
  21.    
  22.  
  23.     $chart['chart_data'][0][0]="String";
  24.     $chart['chart_data'][0][1]="Int";
  25.     $x=1;
  26.     foreach ($arr as $key => $int) {
  27.  
  28.         $chart['chart_data'][1][$x]=$key;
  29.         $chart['chart_data'][2][$x]=$int;
  30.         $x++;
  31.         }
  32.  
  33.  
  34. dump($chart['chart_data']);
  35. SendChartData ($chart);
  36.  
  37.  
  38. ## chartoutput.php
  39.  
  40. <?php
  41. include('db_connect.inc.php');
  42. include('framework.inc.php');
  43. include('charts.php');
  44. $random=rand(0,522332);
  45.  
  46. echo InsertChart ( "charts.swf", "charts_library", "count.php?nocache=$random", 400, 250 );
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top