Easy-to-follow video tutorials help you learn software, creative, and business skills.Become a member
The charts module supports two free charting kits, the Google Chart API and Open Flash Chart. While the Google system delivers a simple graphic to your site, Open Flash Chart puts your data into a dynamic Flash animation that's a lot more eye catching than Google's product. With that pizzazz comes a good deal more complexity, especially when it comes to installing Open Flash Chart. The worst part is that you need a separate module called Open Flash Chart API, and that's not documented anywhere. I'll show you how to install it correctly, but this is a good time to remind you, backup your Drupal database frequently, especially when you are installing new modules to prevent disasters.
For help doing that see the videos from my Drupal Essential Training Course, backing up your Drupal site and restoring your Drupal site from backup. A module that you'll need is called Open Flash Chart API. I've already downloaded and installed this. It's just a matter of turning it on. To turn on that module, we go to Administer > Site building > Modules. Strangely this one isn't in the charts group. Instead, it's in the other group. So I scroll all the way down to the other group, and there is it. I turn that on and scroll down again, and save. Now I have to grab one more piece to make Open Flash Charts work correctly. You'll find it at this URL. Once here you actually have to do quite a bit of scrolling to find out how to download it.
You can also read more about the project. The good thing is like Drupal it's free. The latest version that I'm using is Version 1.9.7. There is a Version 2 coming out, which is quite different as I understand. You may want to look into the possibility of using Version 2 if it's available when you see this. But for us, we click to download. That brings us to its project page, click on the name, and then we can choose the version we want. I've already downloaded it, so I'll show you how to install it. For that, we switch to our finder, and hide everything else. And this is the folder that we got after we expanded the archive that we downloaded. I'll open it up so you can see what's in it. Most of the parts of this Open Flash Chart are actually not needed for our installation. All that we need is this JS folder, and open-flash-chart.swf. I'll just move this out of the way a little bit. We install it by going into that Open Flash Chart API module we downloaded. I'm just dragging those two parts in, JS and open-flash-chart.swf.
Now we are ready to go. I'll close that window and go back to my site. We scroll down again to our charts modules area. Now we turn on Open Flash Chart. If you didn't add that extra piece, this could actually crash your site. Scrolling down further, I click Save configuration. Now our final step it to go back and change the module that charts is looking at. We do with Administer > Site Configuration > Charts and now we can choose Open Flash Charts. I'll leave it as Pie 3D, scroll down and save settings.
And as you could see, it's actually quite a nice display. There is that one color that we changed. Something else that's nice about this is that as you point to a section, it tells you what the actual number is. So you can see, it was a lot of trouble getting here, but it's worth it sometimes. I am going to go back to our view and make sure everything is working, then we'll actually see our chart. Go to Administer > Site Building > Views, and scroll down to find our chart of households and edit it, so that we actually have a place to put this. I'm going to add a display here, and we'll give that page a path, say chart-of-households. Good, scroll down and save that page.
Let's take a look at our chart options and make sure everything is okay. We click on our little gear, scroll down. We want a 2D pie chart. Yup, it looks good. Update default display to save it, and Save. Now let's take a look at our page. Right-click > Open Link in New Tab, and there it is. Now that's a beautiful chart. So you might ask, why am I showing you a system that doesn't work so well? As with any software, you have to look at the cost of implementing something, how hard it is, I mean, and compare it to the benefits. And while the pain of getting this graphing system to work is currently enormous, I expect that to go down as a module matures.
Plus, here are some other options, such as the charts and graphs, and views charts modules, which are also fairly new, but I expect to mature. They are even more listed in the content display category of modules on Drupal.org. I believe the value of turning your data into charts is really high. They have such immediate impact, and no text only information can convey that much.
Get unlimited access to all courses for just $25/month.Become a member
Access exercise files from a button right under the course name.
Search within course videos and transcripts, and jump right to the results.
Remove icons showing you already watched videos if you want to start over.
Make the video wide, narrow, full-screen, or pop the player out of the page into its own window.
Click on text in the transcript to jump to that spot in the video. As the video plays, the relevant spot in the transcript will be highlighted.
Your file was successfully uploaded.