From 6956f7067724427e820f2b015ae03b66fa707df7 Mon Sep 17 00:00:00 2001 From: Ramon Novoa Date: Tue, 30 Jun 2009 16:31:15 +0000 Subject: [PATCH] 2009-06-30 Ramon Novoa * include/functions_fsgraph.php: Truncate long names for flash charts. git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@1781 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f --- pandora_console/ChangeLog | 4 ++++ pandora_console/include/functions_fsgraph.php | 7 ++++--- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/pandora_console/ChangeLog b/pandora_console/ChangeLog index b644e9a9d9..d085fb3d8f 100644 --- a/pandora_console/ChangeLog +++ b/pandora_console/ChangeLog @@ -1,3 +1,7 @@ +2009-06-30 Ramon Novoa + + * include/functions_fsgraph.php: Truncate long names for flash charts. + 2009-06-30 Ramon Novoa * include/fgraph.php: Added support for mixing flash/image charts. diff --git a/pandora_console/include/functions_fsgraph.php b/pandora_console/include/functions_fsgraph.php index ad78319ec9..229441b52b 100644 --- a/pandora_console/include/functions_fsgraph.php +++ b/pandora_console/include/functions_fsgraph.php @@ -274,9 +274,10 @@ function fs_agent_event_chart ($data, $width, $height, $step = 1) { // Clean FLASH string strips non-valid characters for flashchart function clean_flash_string ($string) { $string = html_entity_decode ($string, ENT_QUOTES, "UTF-8"); - $temp = str_replace('&', '', $string); - $temp = str_replace(' ', '', $string); - return str_replace ('"', '', $temp); + $string = str_replace('&', '', $string); + $string = str_replace(' ', '', $string); + $string = str_replace ('"', '', $string); + return substr ($string, 0, 20); } // Prints an error image