开发者

HighCharts: How to pass x and y value of selected point to Rails

I am new to HighChar开发者_如何转开发ts, javascript, and rails. I have a highchart in my rails application. I need to pass the values of the x and y to rails of the point a users clicks on the chart series. I know about the selection event handler but not how to pass data from highcharts to the rails controller. Can someone point me to an example I can look through.

Please help. Thanks


Too late, probably you already have solved this. The selection event handler allows you to fire an event. You can fire an ajax request to a controller method with the values of the point which are accessed using 'this'. Many demos in highcharts show you how to access the values of points using this.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜