function endpointman_configpageload() { global $currentcomponent; // Init vars from $_REQUEST[] $action = isset($_REQUEST['action']) ? $_REQUEST['action'] : null; $extdisplay = isset($_REQUEST['extdisplay']) ? $_REQUEST['extdisplay'] : null; // Don't display this stuff it it's on a 'This xtn has been deleted' page. if ($action != 'del') { $langcode = languages_user_get($extdisplay); $section = _('End Point Manager'); $msgInvalidLanguage = _('Please enter a valid Lajnguage Code'); //$currentcomponent->addguielem($section, new gui_textbox('langcode', $langcode, _('Language Code'), _('This will cause all messages and voice prompts to use the selected language if installed.'), "!isFilename()", $msgInvalidLanguage, true),9); //$currentcomponent->addguielem($section, "",9); } }
function languages_configpageload() { global $currentcomponent; // Init vars from $_REQUEST[] $action = isset($_REQUEST['action']) ? $_REQUEST['action'] : null; $extdisplay = isset($_REQUEST['extdisplay']) ? $_REQUEST['extdisplay'] : null; // Don't display this stuff it it's on a 'This xtn has been deleted' page. if ($action != 'del') { $langcode = languages_user_get($extdisplay); $section = _('Language'); $category = _("General"); $msgInvalidLanguage = _('Please enter a valid Language Code'); if (FreePBX::Modules()->moduleHasMethod('Soundlang', 'getLanguages')) { $langlist = array(array('value' => '', 'text' => _('Default'))); $languages = FreePBX::Soundlang()->getLanguages(); if (!empty($languages)) { foreach ($languages as $key => $val) { $langlist[] = array('value' => $key, 'text' => $val); } } $currentcomponent->addguielem($section, new gui_selectbox('langcode', $langlist, $langcode, _("Language Code"), _("This will cause all messages and voice prompts to use the selected language if installed. Languages can be added or removed in the Sound Languages module"), false), $category); } else { $currentcomponent->addguielem($section, new gui_textbox('langcode', $langcode, _('Language Code'), _('This will cause all messages and voice prompts to use the selected language if installed.'), "!isFilename()", $msgInvalidLanguage, true), $category); } } }