Displaying Graph outside Dashboard


Thank u Vipsoft, based on ur kind guidance i was able to write a plugin for displaying a graph onto the dashboard using Text file as datasource…

the pugin code is…

function pieChart($url = ‘libs/open-flash-chart/data-files/pie-4.txt’)
echo ‘
$pathToLibraryOpenChart = ‘libs/open-flash-chart/’;
$pathToLibrarySwfObject = ‘libs/swfobject/’;

            $url = urlencode($url);
    $requiredFlashVersion = "9.0.0";
            echo 'swfobject.embedSWF(
                    "'. $pathToLibraryOpenChart .'open-flash-chart.swf?piwik='. Piwik_Version::VERSION .'",
                    "350", "250",
                    "'. $requiredFlashVersion .'",
                    "'. $pathToLibrarySwfObject .'expressInstall.swf",
                    //      "loading":"'. htmlspecialchars(Piwik_Translate('General_Loading')) .'"

            echo '<p>Pie Chart</p>

<div id="my_chart"></div>';


Now i am unable to display the graph outside the Dashboard…
i.e localhost/piwik/uploader.php

I need to display the graph in this uploader.php…

Pls kindly help me out to sort out this problem…