From aadd1deb5b21afe7af7f1c7a3498a5569570440e Mon Sep 17 00:00:00 2001 From: PhantomVl Date: Wed, 29 May 2019 20:47:15 +0300 Subject: [PATCH] - Remove spaces and special characters from the name Softkey --- Sccp_manager.class.php | 2 +- views/server.info.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Sccp_manager.class.php b/Sccp_manager.class.php index 14cf855..9ff4fa2 100644 --- a/Sccp_manager.class.php +++ b/Sccp_manager.class.php @@ -845,7 +845,7 @@ class Sccp_manager extends \FreePBX_Helpers implements \BMO { break; case 'updateSoftKey': if (!empty($request['id'])) { - $id_name = $request['id']; + $id_name = preg_replace('/[^A-Za-z0-9]/', '', $request['id']); $this->sccp_conf_init[$id_name]['type'] = "softkeyset"; foreach ($this->extconfigs->getextConfig('keyset') as $keyl => $vall) { if (!empty($request[$keyl])) { diff --git a/views/server.info.php b/views/server.info.php index 42f3406..8f3e123 100644 --- a/views/server.info.php +++ b/views/server.info.php @@ -143,7 +143,7 @@ print_r("
Help Info:
");
                             foreach ($this->info_warning as $key => $value) {
                                 echo '

'.$key.'

'; if (is_array($value)) { - echo '
  • '.implode('
  • ', $value).'
  • '; + echo '
  • '._(implode('
  • ', $value)).'
  • '; } else { echo '
  • '. _($value).'
  • '; }