To register for an Internet.com membership to receive newsletters and white papers, use the Register button ABOVE.
To participate in the message forums BELOW, click here
Code CritiqueHaving someone critique your code is always a great way to hone the skills. Stop in and post your code to see what your peers may have done differently.
2D Pie Chart source code, please feel free to sent me comments, thanks!
PHP Code:
<?php
/********************************
2D Pie Chart Version 1.0
Programer: Xiao Bin Zhao
Date: 03/31/2001
All Rights Reserved 2001.
********************************/
/*************Configuration Starts Here******************/
$chartTitle = "Most Popular Stars"; //pie chart name
$logo = "www.asianstar.com"; //logo
/*************************End****************************/
/*****************For Programers Only********************/
$imageWidth = 300; //image width
$imageHeight = 200; //image height
$diameter = 150; //pie diameter
$centerX = 100; //pie center pixels x
$centerY = 100; //pie center pixels y
$labelWidth = 10; //label width, no need to change
/*************************End****************************/
For instruction installing GD library on Linux( I assumed you using Linux )
please go to:
http://www.e-gineer.com/instructions/install-gd13-for-php-with-apache-on-linux.phtml
If you are not using Linux but Win e-mail me again.
For instruction installing GD library on Linux( I assumed you using Linux )
please go to:
http://www.e-gineer.com/instructions/install-gd13-for-php-with-apache-on-linux.phtml
If you are not using Linux but Win e-mail me again.
Are you using windows? What's the problem?
I used that snippet on a windows php installation and i got no problem.
Anyway,i found this too: http://www.aditus.nu/jpgraph/index.php
Take a look, may be can help you.
Paolo Dina
You can't simply output an array inside of a string. You'll either have to serialize() it, implode() it, or transfer it to the second PHP script by some other means (e.g. a session).
Dont forget that URI's are limited to a certain number of characters (255 or something?).
__________________
***If your problem has been solved, PLEASE click the RESOLVED LINK under "Thread Tools"***
"Well Bones, do the new medical facilities meet with your approval?" -- Kirk
"They do not. It's like working in a damn computer center" -- McCoy (Star Trek: TMP)
Thanks a lot for your help. I noticed the mistake you mentioned but I have tried imploding and exploding, I have even tried passing the variables individually but I just cant seem to get it to work.
Here is my latest version; if anyone can spot a silly mistake then I will be very grateful;
So what's an example of the URL that is outputted?
__________________
***If your problem has been solved, PLEASE click the RESOLVED LINK under "Thread Tools"***
"Well Bones, do the new medical facilities meet with your approval?" -- Kirk
"They do not. It's like working in a damn computer center" -- McCoy (Star Trek: TMP)