<?php

// begin cf_simpleline.cfm 

	// object setup	
	$tchart = new COM("turbochart.tchart");
				
	// setup the colors for the chart 
	$cGreen = $tchart -> rgbcolor(10,160,10);     // green 0AA00A
	$cDGreen = $tchart -> rgbcolor(0,102,0);      // dark green 006600
	$cBlue = $tchart -> rgbcolor(5,104,167);      // blue 0568A7
	$cDBlue = $tchart -> rgbcolor(0,51,102);      // dark blue 003366
	$cRed = $tchart -> rgbcolor(167,28,5);        // red A71C05
	$cDRed = $tchart -> rgbcolor(102,0,0);        // dark red 660000
	$cBlack = $tchart -> rgbcolor(0,0,0);         // black 000000
	$cWhite = $tchart -> rgbcolor(255,255,255);   // white FFFFFF
	$cOrange = $tchart -> rgbcolor(204,129,0);    // orange CC8100
	$cGrey = $tchart -> rgbcolor(246,243,243);    // grey C8C6C6
	$cGrey2 = $tchart -> rgbcolor(221,221,221);   // dark grey 808080
				
	// begin primary chart 
	$tchart -> BeginChart(getcwd() . "\php_simplepie.jpg",1,700,350);
	$tchart -> SetBackGroundColor($tchart -> rgbcolor(221,221,221));
	$tchart -> SetFont("Arial",24,$cBlack, True ,False,0);
	$tchart -> SetTitle("Productivity By Department");
						
		// begin pie chart 
		$tchart -> Pie3dBegin(0,0,700,350,4);
		$tchart -> SetFont("Verdana",18,$cBlack, True ,False,0);
									
		// label slices 
		$tchart -> Pie3dSetSliceLabel("Corporate Sales",0);
		$tchart -> Pie3dSetSliceLabel("Hardware Sales",1);
		$tchart -> Pie3dSetSliceLabel("Software Sales",2);
		$tchart -> Pie3dSetSliceLabel("Consulting",3);
									
		// slice 0 value, color, and position 
		$tchart -> Pie3dSetSliceValue(20,0);
		$tchart -> Pie3dSetSliceColor($cRed,0);
		$tchart -> Pie3dSetSlicePosition(0.0,2,0,0);
								
		// slice 1 value, color, and position 
		$tchart -> Pie3dSetSliceValue(30,1);
		$tchart -> Pie3dSetSliceColor($cBlue, 1);
		$tchart -> Pie3dSetSlicePosition(0.0,2,0,1);
									
		// slice 2 value, color, and position 
		$tchart -> Pie3dSetSliceValue(40,2);
		$tchart -> Pie3dSetSliceColor($cGreen, 2);
		$tchart -> Pie3dSetSlicePosition(0.0,2,0,2);
									
		// slice 3 value, color, and position 
		$tchart -> Pie3dSetSliceValue(10,3);
		$tchart -> Pie3dSetSliceColor($cOrange, 3);
		$tchart -> Pie3dSetSlicePosition(0.0,2,0,3);
									
		// end pie chart 
		$tchart -> Pie3dFinish(0);
						
	// finish primary chart 
	$tchart -> FinishChart(0);

?>	

<img src="php_simplepie.jpg">