Tuesday, 31 July 2012

CFCHART phones home

G'day
Sorry about the lack of post today (or yesterday, depending on your TZ)... I had some family dramas to deal with that needed to take precedence over my waffling.

This is just going to be a quick post too.

Stephen Walker put me onto this via Twitter, and all credit for noticing this goes to him.



Here's some simple <cfchart> code:

And it looks like this:



That's fine (well... let's not pay too much attention the medals there, eh... err... ahem... [cough] early days yet...), but what's interesting is when one right-clicks on this, and opts to save as a PDF (not on the screen cap above -that's just a JPG - you'll need to download and run that code locally.

What <cfchart> does is sends the data down to http://export.zingchart.com/, where the PDF is processed.  That's a bit odd.  As Stephen said on Twitter... CF has a bunch of PDF-generating stuff, why can't the request be sent back to the CF server to do this?  That's what it should do.

I looked in the docs for any reference to this, but there's not a single mention of it.

I really don't think it's appropriate for <cfchart> to be basically "phoning home" (someone else's home at that!) when using this functionality.

Thoughts?

Thanks again to Stephen for giving me something quick to write about today, and for giving me the heads-up to look at <cfchart>: not something I do on a regular basis.

Righto.

--
Adam