Hi Derek,

It would help to see pointers to the actual web pages, so we could see what
the PHP code generates.   We can't really help otherwise.  If you 'view
source' on those pages, you might notice what has gone wrong.

On Sun, Oct 9, 2016 at 2:23 PM, Derek McGuire <dreadedcorpse1...@gmail.com>
wrote:

> I have s script I developed for a CMS and I have been implementing the
> Google Piechart into the system. I just put the updates on my site and a
> few test sites from the CMS community, and on 2 of the 5 sites, and error
> occurs with the piechart.
> I am trying to figure out why on these 2 sites, its not working. The error
> is instead of displaying the piechart as expected, it displays "*a is not
> a function*".
> Below are 2 images, The first screenshot is it working on one of the test
> sites and the other is where it's not. The code that is being used is as
> follows.
>
>   echo '<script type="text/javascript" src="https://www.gstatic.com/
> charts/loader.js"></script>' , PHP_EOL
>       ,'    <script type="text/javascript">
>       google.charts.load("current", {packages:["corechart"]});
>       google.charts.setOnLoadCallback(drawChart);
>       function drawChart() {
>         var data = google.visualization.arrayToDataTable([
>           [\'Task\', \'Bots Caught\'],
>           [\'Wait Script\', '.$waitscript.'],
>           [\'Text Removal\', '.$textremoval.'],
>           [\'Honeypot / Hidden Question\', '.$hidden.'],
>           [\'Custom Question\', '.$customquestion.'],
>           [\'SFS Blacklist\', '.$sfsspam.'],
>           [\'BotScout Blacklist\', '.$bscheck.'],
>           [\'FSpamlist Blacklist\', '.$fscheck.']
>         ]);
>
>         var options = {
>           title: \'Honeypot Blocker Results PieChart\',
>           is3D: true,
>  backgroundColor: \''.$rowcolor2.'\',
>  titleTextStyle: {color: \''.$fontcolor.'\', fontSize: \'32px\'},
>    legendTextStyle: {color: \''.$fontcolor.'\', fontSize: \'16px\'},
>  colors: [\'#00A209\', \'#486EFF\', \'#AB00BC\', \'#C30012\', \'#D08E00\',
> \'#00C3B4\', \'#77D100\'],
>         };
>
>         var chart = new google.visualization.PieChart(
> document.getElementById(\'piechart_3d\'));
>         chart.draw(data, options);
>       }
>     </script>' , PHP_EOL;
>
>
> Working
>
>
> <https://lh3.googleusercontent.com/-gbLVm3QjSbA/V_qKciWxpgI/AAAAAAAAAI8/CSg4TpRAiq8WGOjCu4BTpclz9CH9NuPSwCLcB/s1600/working.jpg>
>
>
> Not working
>
>
> <https://lh3.googleusercontent.com/-TZozlop-DSM/V_qKpsHlsDI/AAAAAAAAAJE/VE27LQ9AH6o5R_tMBOY9EOhzJW-s7OuFgCLcB/s1600/error.jpg>
>
>
> Anyone have any ideas why this does work on 3 out of the 5 sites and on 2
> of them, it would display the error  "*a is not a function*"? Any help
> would be appreciated.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Visualization API" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to google-visualization-api+unsubscr...@googlegroups.com.
> To post to this group, send email to google-visualization-api@
> googlegroups.com.
> Visit this group at https://groups.google.com/
> group/google-visualization-api.
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/google-visualization-api/e6a5a55b-5532-4a22-b268-
> 267712029f5c%40googlegroups.com
> <https://groups.google.com/d/msgid/google-visualization-api/e6a5a55b-5532-4a22-b268-267712029f5c%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>



-- 
Daniel LaLiberte <https://plus.google.com/100631381223468223275?prsrc=2>
dlalibe...@google.com <dlalibe...@google.com>   5CC, Cambridge MA

-- 
You received this message because you are subscribed to the Google Groups 
"Google Visualization API" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-visualization-api+unsubscr...@googlegroups.com.
To post to this group, send email to google-visualization-api@googlegroups.com.
Visit this group at https://groups.google.com/group/google-visualization-api.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-visualization-api/CAOtcSJMGjTD8V1nL_C0%3DuQc%3DVDzpScmP8nyoUH%2BXZogWKRt%2BSg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to