javascript - Highcharts - how to have a chart with dynamic height? -



javascript - Highcharts - how to have a chart with dynamic height? -

i want have chart resizes browser window, problem height fixed 400px. this jsfiddle example has same problem.

how can that? tried using chart.events.redraw event handler resize chart (using .setsize), guess starts never-ending loop (fire event handler, calls setsize, fires event handler, etc.).

just don't set height property in highcharts , handle dynamically long set height on chart's containing element. can fixed number or percent if position absolute.

highcharts docs:

by default height calculated offset height of containing element

example: http://jsfiddle.net/wkkad/149/

#container { height:100%; width:100%; position:absolute; }

javascript highcharts

Comments

Popular posts from this blog

How do I check if an insert was successful with MySQLdb in Python? -

delphi - blogger via idHTTP : error 400 bad request -

postgresql - ERROR: operator is not unique: unknown + unknown -