• We’re currently investigating an issue related to the forum theme and styling that is impacting page layout and visual formatting. The problem has been identified, and we are actively working on a resolution. There is no impact to user data or functionality, this is strictly a front-end display issue. We’ll post an update once the fix has been deployed. Thanks for your patience while we get this sorted.

dynamic web chart creation

Alex

Diamond Member
i have a challenging new project... to take excel-based data and transfer it to mysql and then create a web-based interface for managing it (so far so good) and it would have to draw charts and graphs etc on the fly... now that's where i go WTF! 🙁

i've been learning a lot of AJAX lately and getting more and more comfortable with it and i've read that apparently one of its many uses is for doing stuff like this... on the other hand i've seen FLEX in action and just... wow!

on the other hand i don't know any FLEX or anything Adobe/Macromedia (except Dreamweaver) for that matter...

is AJAX viable? or should i invest the time into learning FLEX for this project? if i can pull it off in a reasonable timeframe it could get adopted by a local company which would be great for me, but it's really more of a personal project than anything..

thanks for any advice and tips! 🙂
 
I'd look for a charting component that works with your server platform and tools.

Is this a Windows (IIS & .NET or Apache?) or linux server?

Is this for internal / company use on one server or a commecial product where you need to redistribute the component to customers?
 
its an apache-based linux server...
could get another one if need be but that's what i have at the moment...

and also at the moment this is a small project but if it works out it could become a commercial product fairly quickly so i want to design it from the ground up as efficient and best as possible
 
There are 2 general approaches, creating bitmap images and using an applet / plugin / data viewer.

There may be some linux chart-generation packages that you can pipe data to, to generate a GIF or JPG on the fly.

There may be a java applet to display graphs that you can embed in a page and feed data to.

I've done the first approach on a Windows server using IIS, ASP, and some C++ Win32 exe image generators, but I haven't done any linux coding. The image generators used Win32 drawing and font commands (GDI) to draw on an offscreen memory buffer, then an image library to save the buffer out to a JPEG.

Image generation is compatible with every browser (even phones) and works even when java isn't installed since the chart is just a .gif, .png, or .jpeg.

An applet requires users to accept it and to have java installed. The main benefits are the load is much lighter on the server, and the applet can possibly render multiple views from one set of data.

Bandwidth use depends on the amount of data -- an x-y plot of 10,000 points will probably use less bandwidth as an image, a chart of 100 values probably requires less to send raw data than a fancy image.
 
i've written plenty of graphing scripts with php using the gd library

there are also plenty of free and ready to download php classes out there to use (some involving flash)

I've heard a lot of good things about flex too, but i don't have any experience with it
 
Originally posted by: troytime
i've written plenty of graphing scripts with php using the gd library

there are also plenty of free and ready to download php classes out there to use (some involving flash)

I've heard a lot of good things about flex too, but i don't have any experience with it

sounds good... yeah i was hoping i could use the gd library... i'll look into both a little more and if anyone else has any advice i'd be happy to read it! 🙂
 
There are quite a few books out there for doing this. Wrox has one I believe... Multimedia programming in PHP or something like that. I have it, several years old and PHP4 only but the info is still ok.

Flex is for lack of a better comparison... Ajax. Action Script 3.0 is pretty hot and you can do serious things with it. But, you can always count on a modern browser rendering a jpg on the screen in all but the most tightly locked down browser settings. Flash, there are a lot of plugins that block flash ads and that is something you have to take into consideration.

I'd go php5 and gd2. Go to Flex when you get some Flash CS3 under your belt.
 
Originally posted by: hooflung
There are quite a few books out there for doing this. Wrox has one I believe... Multimedia programming in PHP or something like that. I have it, several years old and PHP4 only but the info is still ok.

Flex is for lack of a better comparison... Ajax. Action Script 3.0 is pretty hot and you can do serious things with it. But, you can always count on a modern browser rendering a jpg on the screen in all but the most tightly locked down browser settings. Flash, there are a lot of plugins that block flash ads and that is something you have to take into consideration.

I'd go php5 and gd2. Go to Flex when you get some Flash CS3 under your belt.

thanks! 🙂

i'll look into those books and maybe buy one.
this is definitely a skillset i'd like to have! 🙂
 
I've done this sort of thing wiyj open source libs (Perl, PHP) as recently started using Flex. It really is a cool framework and it would be good to learn it. They have a reporting framework that makes it easy to do simple charting. It is pretty expensive though and there are some really cool free charting frameworks out there for Flex...

Check these out
Google-finance-esqe example (right-click to view source.
Similar
Click the bars

Finally, the AJAX libraries do provide some basic charting functionality but most of it would likely be custom.

If you know any object oriented language you will be able to pick up Flex in no time.
 
Originally posted by: hooflung
There are quite a few books out there for doing this. Wrox has one I believe... Multimedia programming in PHP or something like that. I have it, several years old and PHP4 only but the info is still ok.

Flex is for lack of a better comparison... Ajax. Action Script 3.0 is pretty hot and you can do serious things with it. But, you can always count on a modern browser rendering a jpg on the screen in all but the most tightly locked down browser settings. Flash, there are a lot of plugins that block flash ads and that is something you have to take into consideration.

I'd go php5 and gd2. Go to Flex when you get some Flash CS3 under your belt.

Flex is not Ajax. People tend to lump DHTML in with Ajax but it really isn't the same thing. Web2.0 is Ajax mixed with fancy CSS and Javascript UI interaction.

Flex is a Flash based programming model for building the user interface for internet applications. It not only includes the widgets used in the interface but also provides extremely easy integration with a back-end application framework.

Basically Flex makes it extremely easy to create complex user interfaces with an object-oriented language (they even have a declarative langauge).
 
Originally posted by: binister
Originally posted by: hooflung
There are quite a few books out there for doing this. Wrox has one I believe... Multimedia programming in PHP or something like that. I have it, several years old and PHP4 only but the info is still ok.

Flex is for lack of a better comparison... Ajax. Action Script 3.0 is pretty hot and you can do serious things with it. But, you can always count on a modern browser rendering a jpg on the screen in all but the most tightly locked down browser settings. Flash, there are a lot of plugins that block flash ads and that is something you have to take into consideration.

I'd go php5 and gd2. Go to Flex when you get some Flash CS3 under your belt.

Flex is not Ajax. People tend to lump DHTML in with Ajax but it really isn't the same thing. Web2.0 is Ajax mixed with fancy CSS and Javascript UI interaction.

Flex is a Flash based programming model for building the user interface for internet applications. It not only includes the widgets used in the interface but also provides extremely easy integration with a back-end application framework.

Basically Flex makes it extremely easy to create complex user interfaces with an object-oriented language (they even have a declarative langauge).

so basically i'd still have to code a back-end application in java for example to use with flex?

i'd feel more comfortable if i could code the entire thing in PHP + MySQL and then use AJAX or FLEX just for the charting parts... is that not realistic?
 
Originally posted by: alex
Originally posted by: binister
Originally posted by: hooflung
There are quite a few books out there for doing this. Wrox has one I believe... Multimedia programming in PHP or something like that. I have it, several years old and PHP4 only but the info is still ok.

Flex is for lack of a better comparison... Ajax. Action Script 3.0 is pretty hot and you can do serious things with it. But, you can always count on a modern browser rendering a jpg on the screen in all but the most tightly locked down browser settings. Flash, there are a lot of plugins that block flash ads and that is something you have to take into consideration.

I'd go php5 and gd2. Go to Flex when you get some Flash CS3 under your belt.

Flex is not Ajax. People tend to lump DHTML in with Ajax but it really isn't the same thing. Web2.0 is Ajax mixed with fancy CSS and Javascript UI interaction.

Flex is a Flash based programming model for building the user interface for internet applications. It not only includes the widgets used in the interface but also provides extremely easy integration with a back-end application framework.

Basically Flex makes it extremely easy to create complex user interfaces with an object-oriented language (they even have a declarative langauge).

so basically i'd still have to code a back-end application in java for example to use with flex?

i'd feel more comfortable if i could code the entire thing in PHP + MySQL and then use AJAX or FLEX just for the charting parts... is that not realistic?

The back-end application framework can be any based on any language you want... The back-end app acts as a web service to the Flex application. You can use any transport you want (REST, XML) or even roll your own.
 
(Warning: this is totally not a practical idea)

SVG would be a very cool thing do this in. It could be rendered either server side or client side, it would probably be a bit lighter than image generation and none of the ickyness of flash plugins. Browser support, of course, is the problem. Guess which one of the four major browsers is lagging in native, inline svg support?
 
Lord...

That Flex stuff looks pretty awesome. But I like how the Web is being pulled in two completely (by definition) directions:

On the one hand, you have Ajax, and Flex, and these systems and environments and infrastructures to build media-rich, content-aware, buzzword-buzzword websites, that pretty much blow away what stand alone desktop apps can do, and then on the other, you have this huge push toward mobile and ubiquitous computing.

Um, hello? McFly?

I mean, I'm looking into building the end-all, be-all NBA analysis site (picture Basketball-reference.com mixed with 82games.com mixed with blogging/analysis mixed with stuff you've never seen) and I'm constantly flip flopping between how to built a content rich, interesting, "Web 2.0" experience (whatever that means) and making it so people on mobile devices can access it quickly and cleanly.

Does Flex degrade? 😀

Anyway, that platform looks pretty sweet. For Flash-enabled devices, I guess. (It just builds flash apps quickly, right)
 
flex is looking more and more like the best alternative and i've seen some pretty amazing things done with a simple xml file served to it for data.

however i heard about using java to build the back-end and flex for the front-end... can someone explain to me a little better how this would work in a server environment?
i'm comfortable with creating java apps that read and write xml but how would it work with creating an interface for the user to update information etc? it would have to an applet right?
 
Back
Top