diff --git a/README.md b/README.md index 18ae15c..cd358a3 100644 --- a/README.md +++ b/README.md @@ -34,7 +34,11 @@ Added arTableExists and arFieldExists to be compatible with 9.2 Remove functions for 9.1 compatibility ## 2.3.3 +Compatibility with GLPI 9.2 Fixed issue with the \r\n ## 2.4.0 +Compatibility with GLPI 9.3 + +## 2.5.0 Compatibility with GLPI 9.4 diff --git a/hook.php b/hook.php index 485bb1a..3d6b31b 100644 --- a/hook.php +++ b/hook.php @@ -223,13 +223,8 @@ public static function cleanText($parm) { //////////////////// // GLPI fixes - // cases of the \r\n or \n for GLPI 9.2, and what about GLPI 9.3? - $temp_content = preg_replace('/(\\\\r)?\\\\n/', ';,
', $temp_content); - // cases of the " that are converted into '; instead of " in GLPI 9.2, 9.3 and 9.4 $temp_content = str_replace('\\\';', '\\"', $temp_content); - // backport of addslashes_deep from GLPI 9.4/bugfixes, completes the one from GLPI 9.2 - $temp_content = str_replace(['''], ["'"], $temp_content); // End of GLPI fixes //////////////////// diff --git a/setup.php b/setup.php index 0c755b7..e2de581 100644 --- a/setup.php +++ b/setup.php @@ -8,7 +8,7 @@ // and it cleans attached pictures to emails // It has been succesfully tested with plain TEXT and HTML emails // ---------------------------------------------------------------------- -define ("PLUGIN_TICKETCLEANER_VERSION", "2.4.0"); +define ("PLUGIN_TICKETCLEANER_VERSION", "2.5.0"); /** * Summary of plugin_init_ticketcleaner @@ -28,11 +28,11 @@ function plugin_init_ticketcleaner() { $PLUGIN_HOOKS['pre_item_add']['ticketcleaner'] = [ 'Ticket' => ['PluginTicketCleaner', 'plugin_pre_item_add_ticketcleaner'], - 'TicketFollowup' => ['PluginTicketCleaner', 'plugin_pre_item_add_ticketcleaner_followup'] + 'ITILFollowup' => ['PluginTicketCleaner', 'plugin_pre_item_add_ticketcleaner_followup'] ]; $PLUGIN_HOOKS['pre_item_update']['ticketcleaner'] = [ 'Ticket' => ['PluginTicketCleaner', 'plugin_pre_item_update_ticketcleaner'], - 'TicketFollowup' => ['PluginTicketCleaner', 'plugin_pre_item_update_ticketcleaner_followup'] + 'ITILFollowup' => ['PluginTicketCleaner', 'plugin_pre_item_update_ticketcleaner_followup'] ]; $plugin = new Plugin(); diff --git a/ticketcleaner.xml b/ticketcleaner.xml index 5ad0ddb..90a9ced 100644 --- a/ticketcleaner.xml +++ b/ticketcleaner.xml @@ -60,6 +60,10 @@ This plugin adds the possibility to translate it 'inline', see wiki.]]> 2.4.0 9.3 + + 2.5.0 + 9.4 + Any