GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
Already on GitHub? Sign in to your account
Original author: marcis.p...@gmail.com (December 13, 2007 17:15:52)
What steps will reproduce the problem?
Original issue: http://code.google.com/p/flot/issues/detail?id=15
From olau%iol...@gtempaccount.com on December 13, 2007 18:50:10
Would you please try debugging it?
Otherwise please provide a test page to allow someone else to try.
From marcis.p...@gmail.com on February 18, 2008 14:35:03
Here some example:
From marcis.p...@gmail.com on March 13, 2008 14:29:02
tried the same example with flot 0.4. the same error ;/
From olau%iol...@gtempaccount.com on March 13, 2008 16:43:46
I went to that page and it casts an exception: "Invalid dimensions for plot, width =
0, height = 0". This means that the placeholder object hasn't got the dimensions set
at the time where you try to do the plot.
In your case this is probably because the placeholder is hidden (display:none) at the
moment you call $.plot. You need to refactor your code to prevent this. I don't know
what thickbox is doing so I can't tell what would work best, but a quick fix would
perhaps be to just wait a short moment with setTimer().
In short: this is not a Flot bug as the canvas must have its dimensions set before
Flot can do anything.
My apologies for it taking so long. I can recommend using the mailing list in the
future - in fact there was a discussion today about the same kind of problem. It's
available like a web forum with the Google Groups web interface.
From olau%iol...@gtempaccount.com on March 14, 2008 10:40:35
I did a couple of tests, and I'm beginning to think that the problem isn't that the
placeholder is hidden at the moment you call $.plot but rather that the DOM isn't
ready yet. It's just a theory, but it might be related to the fact that you doing the
plot inside an iframe.
I found this link which might help:
From olau%iol...@gtempaccount.com on March 14, 2008 12:52:37
Hm, did some more testing. The results seem to contradict what I just said.