diff options
Diffstat (limited to 'frontends/php/chart.php')
| -rw-r--r-- | frontends/php/chart.php | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/frontends/php/chart.php b/frontends/php/chart.php index 538aa894..d19b94dc 100644 --- a/frontends/php/chart.php +++ b/frontends/php/chart.php @@ -16,7 +16,7 @@ $period=3600; } - if(isset($from)) + if(isset($HTTP_GET_VARS["from"])) { $from=$HTTP_GET_VARS["from"]; } @@ -38,6 +38,8 @@ Header( "Content-type: image/png"); Header( "Expires: Mon, 17 Aug 1998 12:51:50 GMT"); + check_authorisation(); + $im = imagecreate($sizeX+$shiftX+61,$sizeY+2*$shiftY+40); $red=ImageColorAllocate($im,255,0,0); @@ -56,6 +58,14 @@ ImageFilledRectangle($im,0,0,$sizeX+$shiftX+61,$sizeY+2*$shiftY+40,$white); ImageRectangle($im,0,0,$x-1,$y-1,$black); + if(!check_right("Item","R",$HTTP_GET_VARS["itemid"])) + { +// show_table_header("<font color=\"AA0000\">No permissions !</font>"); +// show_footer(); + ImagePng($im); + ImageDestroy($im); + exit; + } for($i=0;$i<=$sizeY;$i+=$sizeY/5) { |
