if ($chart->getId() === 'Stats_2016') {
$chart->setOptions(array(
'vAxis' => array('title' => "Stats"), 'hAxis' => array('title' => "Division"),
));
}--
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-visualizati...@googlegroups.com.
To post to this group, send email to google-visua...@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/ba870895-5dba-4763-bc9c-d3229b941606%40googlegroups.com.
I suspect you are not actually getting the options structure in the browser that you believe you are based on your server side code. Can you point us to a web page that shows the chart you are drawing?
On Thu, May 19, 2016 at 10:55 AM, Yousef El-Khalili <yousef.el...@gmail.com> wrote:
This is the code I'm using to set the titles:if ($chart->getId() === 'Stats_2016') {$chart->setOptions(array('vAxis' => array('title' => "Stats"),'hAxis' => array('title' => "Division"),));}
On Thursday, May 19, 2016 at 10:44:16 AM UTC-4, Yousef El-Khalili wrote:I'm generating a google column chart and I have this as my options array (taken from the page source after the chart is generated)options: {"title":"Overall Stats","height":350,"vAxis":{"title":"Stats"},"hAxis":{"title":"Division"}},However, this sets "Division" to both the horizontal and vertical axes for some reason.Does anyone know why?
--
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+unsub...@googlegroups.com.
To post to this group, send email to google-visua...@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/ba870895-5dba-4763-bc9c-d3229b941606%40googlegroups.com.
Can you please elaborate on what you mean. I'm using a PHP generator to generate these webpages based on a database so I don't have access to JS code to modify it. I have to use PHP using a mehtod called OnPrepareChart($chart) to insert these options, most of the options work except setting titles to the axes. Here's a picture of the chart.No matter what I do, it displays it on both axes. It seems that hAxis has precedence over the vAxis in the sense that if I only specify a vAxis title, it will display that on both axes but if I specify both, it will pick the hAxis to display.Thank you for your reply
On Thursday, May 19, 2016 at 1:34:09 PM UTC-4, Daniel LaLiberte wrote:
I suspect you are not actually getting the options structure in the browser that you believe you are based on your server side code. Can you point us to a web page that shows the chart you are drawing?
On Thu, May 19, 2016 at 10:55 AM, Yousef El-Khalili <yousef.el...@gmail.com> wrote:
This is the code I'm using to set the titles:if ($chart->getId() === 'Stats_2016') {$chart->setOptions(array('vAxis' => array('title' => "Stats"),'hAxis' => array('title' => "Division"),));}
On Thursday, May 19, 2016 at 10:44:16 AM UTC-4, Yousef El-Khalili wrote:I'm generating a google column chart and I have this as my options array (taken from the page source after the chart is generated)options: {"title":"Overall Stats","height":350,"vAxis":{"title":"Stats"},"hAxis":{"title":"Division"}},However, this sets "Division" to both the horizontal and vertical axes for some reason.Does anyone know why?
--
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-visualizati...@googlegroups.com.
To post to this group, send email to google-visua...@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/ba870895-5dba-4763-bc9c-d3229b941606%40googlegroups.com.
--
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-visualizati...@googlegroups.com.
To post to this group, send email to google-visua...@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/1246e034-fbd2-48b9-be11-0b365446e007%40googlegroups.com.