$submit = True; } if ($value['select']) { $object->addEntry($value['name'], $XML_SERVER . '&action=dselect&msg=' . $msg . '&dpage=' . $dpage . '&dindex=' . $key, '', 1); } else { $object->addEntry($value['name'], $XML_SERVER . '&action=dselect&msg=' . $msg . '&dpage=' . $dpage . '&dindex=' . $key, '', 2); } if ($key == $dindex) { $object->setDefaultIndex($rank); } $rank++; } $index++; } # Icons $object->addIcon('1', '0000000804020C30C0000000'); $object->addIcon('2', '000000000000000000000000'); # Softkeys $object->addSoftkey('1', Aastra_get_label('Select', $language), 'SoftKey:Select'); if ($dpage != '1') { $object->addSoftkey('2', Aastra_get_label('Previous', $language), $XML_SERVER . '&action=forward2&msg=' . $msg . '&dpage=' . ($dpage - 1)); } $object->addSoftkey('3', Aastra_get_label('Reverse', $language), $XML_SERVER . '&action=reverse&msg=' . $msg . '&dpage=' . $dpage); if ($submit) { $object->addSoftkey('4', Aastra_get_label('Submit', $language), $XML_SERVER . '&action=dsubmit&msg=' . $msg); } if ($dpage != $last) { $object->addSoftkey('5', Aastra_get_label('Next', $language), $XML_SERVER . '&action=forward2&msg=' . $msg . '&dpage=' . ($dpage + 1)); } $object->addSoftkey('6', Aastra_get_label('Cancel', $language), $XML_SERVER . '&action=detail&msg=' . $msg); } else {
$object->addSoftkey('3', Aastra_get_label('Previous Page', $language), $XML_SERVER . '&action=list&lookup=' . $lookup . '&page=' . ($page - 1), 14); } if ($lookup == '') { $object->addSoftkey('5', Aastra_get_label('Lookup', $language), $XML_SERVER . '&action=search', 15); } else { $object->addSoftkey('4', Aastra_get_label('List Mode', $language), $XML_SERVER . '&action=list', 16); $object->addSoftkey('5', Aastra_get_label('New Lookup', $language), $XML_SERVER . '&action=search', 15); } $object->addSoftkey('7', Aastra_get_label('Preferences', $language), $XML_SERVER . '&action=prefs&lookup=' . $lookup . '&page=' . $page, 17); if ($page != $last) { $object->addSoftkey('8', Aastra_get_label('Next Page', $language), $XML_SERVER . '&action=list&lookup=' . $lookup . '&page=' . ($page + 1), 18); } $object->addSoftkey('10', Aastra_get_label('Exit', $language), 'SoftKey:Exit', 19); # Icons if (Aastra_is_icons_supported()) { $object->addIcon('1', 'Icon:PresenceAvailable'); $object->addIcon('2', 'Icon:PresenceNotAvailable'); $object->addIcon('3', 'Icon:PhoneRinging'); $object->addIcon('4', 'Icon:PhoneOffHook'); $object->addIcon(10, 'Icon:PhoneDial'); $object->addIcon(11, 'Icon:Speaker'); $object->addIcon(12, 'Icon:Add'); $object->addIcon(13, 'Icon:ArrowLeft'); $object->addIcon(14, 'Icon:ArrowUp'); $object->addIcon(15, 'Icon:Search'); $object->addIcon(16, 'Icon:Book'); $object->addIcon(17, 'Icon:Settings'); $object->addIcon(18, 'Icon:ArrowDown'); $object->addIcon(19, 'Icon:CircleRed'); } } else {
$label = $array_user[$key]; } else { $label = '.....................'; } if ($is_icons) { $icon = $value[0]; } else { $icon = ''; $label = $value[1] . ' ' . $label; } $object->addEntry($label, $XML_SERVER . '&action=edit_info&type=' . $key, $key, $icon); } # Icons if ($is_icons) { if (Aastra_phone_type() != 5) { $object->addIcon(1, Aastra_get_custom_icon('Cellphone')); $object->addIcon(2, Aastra_get_custom_icon('Home')); $object->addIcon(3, Aastra_get_custom_icon('Phone')); } else { $object->addIcon(1, 'Icon:CellPhone'); $object->addIcon(2, 'Icon:Home'); $object->addIcon(3, 'Icon:PhoneOnHook'); } } # Softkeys if ($nb_softkeys) { if ($nb_softkeys == 6) { $object->addSoftkey('1', Aastra_get_label('Edit', $language), 'SoftKey:Select'); $object->addSoftkey('2', Aastra_get_label('Clear', $language), $XML_SERVER . '&action=clear_info'); $object->addSoftkey('5', Aastra_get_label('Back', $language), $XML_SERVER); $object->addSoftkey('6', Aastra_get_label('Exit', $language), 'SoftKey:Exit');
} else { # 6739i $object->addSoftkey('1', Aastra_get_label('Toggle', $language), $XML_SERVER . '&action=change'); if ($day == 1) { $object->addSoftkey('6', Aastra_get_label('All DAY', $language), $XML_SERVER . '&action=day'); } if ($night == 1) { $object->addSoftkey('7', Aastra_get_label('All NIGHT', $language), $XML_SERVER . '&action=night'); } $object->addSoftkey('10', Aastra_get_label('Exit', $language), 'SoftKey:Exit'); } } # Icons if ($is_icons) { if (Aastra_phone_type() != 5) { $object->addIcon(1, '00003E4E4A4E3E0000000000'); $object->addIcon(2, '00004E8E8A8E7E0000000000'); } else { $object->addIcon(1, 'Icon:Lock'); $object->addIcon(2, 'Icon:UnLock'); } } break; # Change values # Change values case 'change': # Authenticate user if ($action == 'change') { Aastra_check_signature_Asterisk($user); } # Retrieve all status
$name = $i + 1 . '. ' . $name; } } $object->addEntry($name, $XML_SERVER . '&action=set_speed&speed=' . $i, ''); } # Softkeys if ($nb_softkeys) { if ($nb_softkeys == 6) { $object->addSoftkey('1', Aastra_get_label('Select', $language), 'SoftKey:Select'); $object->addSoftkey('4', Aastra_get_label('Cancel', $language), $XML_SERVER . '&action=zoom'); $object->addSoftkey('6', Aastra_get_label('Exit', $language), 'SoftKey:Exit'); } else { $object->addSoftkey('9', Aastra_get_label('Cancel', $language), $XML_SERVER . '&action=zoom', 1); $object->addSoftkey('10', Aastra_get_label('Exit', $language), 'SoftKey:Exit', 2); $object->setCancelAction($XML_SERVER . '&action=zoom'); $object->addIcon(1, 'Icon:PresenceNotAvailable'); $object->addIcon(2, 'Icon:CircleRed'); } } break; # Set speed dial # Set speed dial case 'set_speed': # Retrieve session $array = Aastra_read_session('csv_directory'); $temp = unserialize(base64_decode($array['csv_directory'])); $directory = $temp[1]; # Update global variable $XML_SERVER .= '&lookup=' . $lookup . '&lastn=' . $lastn . '&firstn=' . $firstn . '&index=' . $index . '&page=' . $page . '&company=' . $company; # Get user context if ($asterisk) {
if ($display['work'] != '') { $object->addEntry($title['W'] . ' ' . $display['work'], $dial['work'], '', '', $dial['work']); } if ($display['mobile'] != '') { $object->addEntry($title['M'] . ' ' . $display['mobile'], $dial['mobile'], '', '', $dial['mobile']); } if ($display['home'] != '') { $object->addEntry($title['H'] . ' ' . $display['home'], $dial['home'], '', '', $dial['home']); } if ($display['other'] != '') { $object->addEntry($title['O'] . ' ' . $display['other'], $dial['other'], '', '', $dial['other']); } } $object->addSoftkey('1', Aastra_get_label('Dial', $language), 'SoftKey:Dial2'); if ($is_icons) { $object->addIcon(1, '000000FEAEFAAEFE00000000'); $object->addIcon(2, '000000007E565AFE00000000'); $object->addIcon(3, '000000103E7A3E1000000000'); $object->addIcon(4, '000000664E5A4E6600000000'); } break; } } if ($is_softkeys) { $object->addSoftkey('4', Aastra_get_label('Back', $language), $XML_SERVER . '?action=list&lookup=' . $lookup . '&page=' . $page . '&selection=' . $selection); $object->addSoftkey('6', Aastra_get_label('Exit', $language), 'SoftKey:Exit'); } break; } # Display XML object $object->output();
$object->addSoftkey('2', Aastra_get_label('Options', $language), $XML_SERVER . '&action=options&origin=list'); if ($page != 1) { $object->addSoftkey('3', Aastra_get_label('Previous Page', $language), $XML_SERVER . '&page=' . ($page - 1)); } $object->addSoftkey('4', Aastra_get_label('Call back', $language), $XML_SERVER . '&action=callback&origin=list'); $object->addSoftkey('5', Aastra_get_label('Forward', $language), $XML_SERVER . '&action=forward&origin=list'); $object->addSoftkey('6', Aastra_get_label('Delete', $language), $XML_SERVER . '&orig_d=list&action=del_message'); $object->addsoftkey('7', Aastra_get_label('Change User', $language), $XML_SERVER_PATH . 'vmail.php?ext=' . $ext); if ($page != $last_page) { $object->addSoftkey('8', Aastra_get_label('Next Page', $language), $XML_SERVER . '&page=' . ($page + 1)); } $object->addsoftkey('9', Aastra_get_label('Detail Mode', $language), $XML_SERVER . '&action=detail'); $object->addSoftkey('10', Aastra_get_label('Exit', $language), 'SoftKey:Exit'); # Icons if (Aastra_is_icons_supported()) { $object->addIcon('1', 'Icon:Envelope'); $object->addIcon('2', 'Icon:EnvelopeOpen'); } break; # Message zoom # Message zoom case 'detail': case 'playing': # Retrieve current message $message = message_context($messages, $msg); # Message not found if (!$message['found']) { # Error message $err_title = sprintf(Aastra_get_label('Mailbox %s', $language), $user); $err_text = Aastra_get_label('Failed to retrieve Message.', $language); $err_key = array('6', Aastra_get_label('Continue', $language), $XML_SERVER . '&action=detail');
# Straight to the directory require_once 'AastraIPPhoneExecute.class.php'; $object = new AastraIPPhoneExecute(); $object->addEntry($ARRAY_CONFIG[$first_source]['uri']); break; # More than one # More than one default: # Display selection require_once 'AastraIPPhoneTextMenu.class.php'; $object = new AastraIPPhoneTextMenu(); $object->setDestroyOnExit(); $object->setTitle(Aastra_get_label('Directory Selection', $language)); foreach ($ARRAY_CONFIG as $source => $value) { $object->addEntry($value['label'], $value['uri'] . '&back=1'); } # Softkeys if ($nb_softkeys) { if ($nb_softkeys == 6) { $object->addSoftkey('1', Aastra_get_label('Select', $language), 'SoftKey:Select'); $object->addSoftkey('6', Aastra_get_label('Exit', $language), 'SoftKey:Exit'); } else { $object->addSoftkey('10', Aastra_get_label('Exit', $language), 'SoftKey:Exit', 1); $object->addIcon(1, 'Icon:CircleRed'); } } break; } # Send XML answer $object->output(); exit;
function zoom($index, $recentPage, $recentSelection) { # Find record matching the given index foreach ($this->_list as $record) { if ($record['index'] == $index) { $myrecord = $record; break; } } # Textmenu for the zoom $menu = new AastraIPPhoneTextMenu(); $menu->setDestroyOnExit(); if (Aastra_is_style_textmenu_supported()) { $menu->setStyle('none'); } if (Aastra_is_wrap_title_supported()) { $menu->setTitleWrap(); } if (Aastra_is_textmenu_wrapitem_supported()) { $menu->setWrapList(); } $menu->setTitle($myrecord['name']); # Default Index $defaultIndex = 1; if (!empty($myrecord['title'])) { $menu->addEntry($myrecord['title'], NULL, NULL); $defaultIndex++; } if (!empty($myrecord['department'])) { $menu->addEntry($myrecord['department'], NULL, NULL); $defaultIndex++; } if (!empty($myrecord['company'])) { $menu->addEntry($myrecord['company'], NULL, NULL); $defaultIndex++; } $menu->setDefaultIndex($defaultIndex); # If Dial2 softkey is supported, add 'Dial:' Prefix to URL (so number can be dialed by pressing right navigation key) if (!Aastra_test_phone_version('2.0.1.', 1)) { $URLprefix = 'Dial:'; } else { $URLprefix = ''; } # Office Number if (!empty($myrecord['office'])) { if (Aastra_is_icons_supported()) { $iconIndex = 10; $prompt = ''; } else { $iconIndex = NULL; $prompt = Aastra_get_label('(W)', $this->_language) . ' '; } if (!Aastra_test_phone_version('2.0.1.', 1)) { $menu->addEntry($prompt . $myrecord['office'], $URLprefix . $myrecord['officeDigits'], $myrecord['officeDigits'], $iconIndex, $myrecord['officeDigits']); } else { $menu->addEntry($prompt . $myrecord['office'], $URLprefix . $myrecord['officeDigits'], $myrecord['officeDigits']); } } # Office 2 number if (!empty($myrecord['office2'])) { if (Aastra_is_icons_supported()) { $iconIndex = 10; $prompt = ''; } else { $iconIndex = NULL; $prompt = Aastra_get_label('(W)', $this->_language) . ' '; } if (!Aastra_test_phone_version('2.0.1.', 1)) { $menu->addEntry($prompt . $myrecord['office2'], $URLprefix . $myrecord['office2Digits'], $myrecord['officeDigits'], $iconIndex, $myrecord['office2Digits']); } else { $menu->addEntry($prompt . $myrecord['office2'], $URLprefix . $myrecord['office2Digits'], $myrecord['officeDigits']); } } # Mobile number if (!empty($myrecord['mobile'])) { if (Aastra_is_icons_supported()) { $iconIndex = 11; $prompt = ''; } else { $iconIndex = NULL; $prompt = Aastra_get_label('(C)', $this->_language) . ' '; } if (!Aastra_test_phone_version('2.0.1.', 1)) { $menu->addEntry($prompt . $myrecord['mobile'], $URLprefix . $myrecord['mobileDigits'], $myrecord['officeDigits'], $iconIndex, $myrecord['mobileDigits']); } else { $menu->addEntry($prompt . $myrecord['mobile'], $URLprefix . $myrecord['mobileDigits'], $myrecord['officeDigits']); } } # Home number if (!empty($myrecord['home'])) { if (Aastra_is_icons_supported()) { $iconIndex = 12; $prompt = ''; } else { $iconIndex = NULL; $prompt = Aastra_get_label('(H)', $this->_language) . ' '; } if (!Aastra_test_phone_version('2.0.1.', 1)) { $menu->addEntry($prompt . $myrecord['home'], $URLprefix . $myrecord['homeDigits'], $myrecord['officeDigits'], $iconIndex, $myrecord['homeDigits']); } else { $menu->addEntry($prompt . $myrecord['home'], $URLprefix . $myrecord['homeDigits'], $myrecord['officeDigits']); } } # Softkeys if (Aastra_is_softkeys_supported()) { if (Aastra_number_softkeys_supported() != 10) { # Regular phone with 6 softkeys if (!Aastra_test_phone_version('2.0.1.', 1)) { $dialKeyType = 'SoftKey:Dial2'; } else { $dialKeyType = 'SoftKey:Dial'; } $menu->addSoftkey(1, Aastra_get_label('Dial', $this->_language), $dialKeyType); $menu->addSoftkey(3, Aastra_get_label('Back', $this->_language), $this->_scrollHandlerReference . '&listPage=' . $recentPage . '&recentSelection=' . $recentSelection); $menu->addSoftkey(6, Aastra_get_label('Exit', $this->_language), 'SoftKey:Exit'); # Check if speed dial URL is set if (isset($myrecord['speedURL'])) { $menu->addSoftkey(4, Aastra_get_label('Add to Speed Dial', $this->_language), $myrecord['speedURL']); } } else { # 6739i $menu->addSoftkey(9, Aastra_get_label('Back', $this->_language), $this->_scrollHandlerReference . '&listPage=' . $recentPage . '&recentSelection=' . $recentSelection, 8); $menu->addSoftkey(10, Aastra_get_label('Exit', $this->_language), 'SoftKey:Exit', 9); # Check if speed dial URL is set if (isset($myrecord['speedURL'])) { $menu->addSoftkey(6, Aastra_get_label('+Speed', $this->_language), $myrecord['speedURL']); } } } # Icons if (Aastra_is_icons_supported()) { if (Aastra_phone_type() != 5) { $menu->addIcon(10, Aastra_get_custom_icon('Office')); $menu->addIcon(11, Aastra_get_custom_icon('Cellphone')); $menu->addIcon(12, Aastra_get_custom_icon('Home')); } else { $menu->addIcon(8, 'Icon:ArrowLeft'); $menu->addIcon(9, 'Icon:CircleRed'); $menu->addIcon(10, 'Icon:Office'); $menu->addIcon(11, 'Icon:CellPhone'); $menu->addIcon(12, 'Icon:Home'); } } # Cancel action $menu->setCancelAction($this->_scrollHandlerReference . '&listPage=' . $recentPage . '&recentSelection=' . $recentSelection); # Display XML object $menu->output(); }
$menu->setTitle('Please select a detail for ' . $contact['first_name'] . ' ' . $contact['last_name']); $menu->setDestroyOnExit(); if ($contact['tel']) { $menu->addEntry($contact['tel'], null, null, '1', $contact['tel']); } if ($contact['home']) { $menu->addEntry($contact['home'], null, null, '2', $contact['home']); } if ($contact['mobile']) { $menu->addEntry($contact['mobile'], null, null, '3', $contact['mobile']); } $menu->natsortByName(); $menu->addSoftkey('5', 'Back', $XML_SERVER_PATH . 'contactdir.php?user='******'&searchmethod=' . $searchmethod . '&search=' . $search); $menu->addSoftkey('6', 'Dial', 'SoftKey:Dial2'); $menu->addSoftkey('3', 'Exit', 'SoftKey:Exit'); $menu->addIcon('1', '000000664E5A4E6600000000'); $menu->addIcon('2', '000000103E7A3E1000000000'); $menu->addIcon('3', '000000007E565AFE00000000'); $menu->output(); } else { //if they dont have details, notify and promt for new search /* $text->setTitle('Error'); $text->setText('No Details Found!'); $text->setDestroyOnExit(); $text->setRefresh('3',$XML_SERVER_PATH.'contactdir.php?user='******'&searchmethod='.$searchmethod.'&search='.$search); $text->output(); */ $screen->setdestroyOnExit(); $screen->setBeep(); $screen->addLine(''); $screen->addLine('No Details Found', 'double', 'center');
$icon = ''; $label = $value[1] . ' ' . $label; } $object->addEntry($label, $XML_SERVER . '&action=set_prefs&state=' . $state . '&value1=' . AA_PRESENCE_ACT_CFWD . '&type=' . $array_user[$key], '', $icon); } } # Manuel entry if ($is_icons) { $icon = '4'; } else { $icon = ''; } $object->addEntry(Aastra_get_label('Enter Number', $language), $XML_SERVER . '&action=edit_number1&state=' . $state, '', $icon); # Icons if ($is_icons) { $object->addIcon(1, Aastra_get_custom_icon('Cellphone')); $object->addIcon(2, Aastra_get_custom_icon('Home')); $object->addIcon(3, Aastra_get_custom_icon('Phone')); $object->addIcon(4, Aastra_get_custom_icon('Keypad')); } # Softkeys if ($nb_softkeys) { if ($nb_softkeys == 6) { $object->addSoftkey('1', Aastra_get_label('Select', $language), 'SoftKey:Select'); $object->addSoftkey('5', Aastra_get_label('Cancel', $language), $XML_SERVER . '&action=input_prefs2&state=' . $state); $object->addSoftkey('6', Aastra_get_label('Exit', $language), 'SoftKey:Exit'); } else { $object->addSoftkey('9', Aastra_get_label('Cancel', $language), $XML_SERVER . '&action=input_prefs2&state=' . $state); $object->addSoftkey('10', Aastra_get_label('Exit', $language), 'SoftKey:Exit'); } }
} $object->addEntry($name, $XML_SERVER . '&action=refresh&page=' . $page . '&confno=' . $confno . '&mode=' . $mode, $new_selection . '&user_id=' . $value[0], $icon); $new_selection++; } $index++; } # Timeout $object->setTimeout('120'); # Default value if (isset($selection)) { $object->setDefaultIndex($selection); } # Icons if ($is_icons) { if (Aastra_phone_type() != 5) { $object->addIcon('1', Aastra_get_custom_icon('Speaker')); $object->addIcon('2', Aastra_get_custom_icon('Muted')); } else { $object->addIcon(1, 'Icon:Speaker'); $object->addIcon(2, 'Icon:Mute'); } } # Softkeys if ($nb_softkeys == 6) { if ($mode == 'admin') { $object->addSoftkey(1, Aastra_get_label('(Un)Mute', $language), $XML_SERVER . '&action=mute&page=' . $page . '&confno=' . $confno . '&mode=' . $mode); $object->addSoftkey(3, Aastra_get_label('Kick', $language), $XML_SERVER . '&action=kick&page=' . $page . '&confno=' . $confno . '&mode=' . $mode); } if ($page != 1) { $object->addSoftkey(2, Aastra_get_label('Previous', $language), $XML_SERVER . '&action=display&page=' . ($page - 1) . '&confno=' . $confno . '&mode=' . $mode); }
if ($unpause_all) { $object->addSoftkey('7', Aastra_get_label('UNPAUSE', $language), $XML_SERVER . '&action=unpause_all'); } if ($last != $page) { $object->addSoftkey('8', Aastra_get_label('Next Page', $language), $XML_SERVER . '&action=show_queues_page&page=' . ($page + 1)); } if ($logoff_all) { $object->addSoftkey('9', Aastra_get_label('LOGOFF', $language), $XML_SERVER . '&action=logoff_all'); } $object->addSoftkey('10', Aastra_get_label('Exit', $language), 'SoftKey:Exit'); } } # Icons if ($is_icons) { if (Aastra_phone_type() != 5) { $object->addIcon('1', '0000FE8282828282FE000000'); //Logged off Dynamic $object->addIcon('2', '0000FEC6AA92AAC6FE000000'); //Logged on Dynamic $object->addIcon('3', '0000FE868A92A2C2FE000000'); //Paused Dynamic $object->addIcon('4', '0000FEFEFEFEFEFEFE000000'); //Logged on Static $object->addIcon('5', '0000FE868E9EBEFEFE000000'); //Paused Static } else { $object->addIcon(1, 'Icon:CircleRed'); $object->addIcon(2, 'Icon:CheckBoxCheck'); $object->addIcon(3, 'Icon:CircleYellow'); $object->addIcon(4, 'Icon:CircleGreen'); $object->addIcon(5, 'Icon:CircleBlue');
$object->addSoftkey('2', Aastra_get_label('Previous', $language), $XML_SERVER . '&action=list&page=' . ($page - 1)); } $object->addSoftkey('3', Aastra_get_label('Prefs', $language), $XML_SERVER . '&action=prefs&lookup=' . $lookup . '&page=' . $page); if ($page != $last) { $object->addSoftkey('5', Aastra_get_label('Next', $language), $XML_SERVER . '&action=list&page=' . ($page + 1)); } if ($lookup != '') { $object->addSoftkey('4', Aastra_get_label('List', $language), $XML_SERVER . '&action=list'); } else { $object->addSoftkey('4', Aastra_get_label('Exit', $language), 'SoftKey:Exit'); } $object->addSoftkey('6', Aastra_get_label('More', $language), $XML_SERVER . '&action=list&menu_set=1&lookup=' . $lookup); } } # Icons $object->addIcon('1', Aastra_get_custom_icon('Available')); $object->addIcon('2', Aastra_get_custom_icon('DND')); $object->addIcon('3', Aastra_get_custom_icon('Bell')); $object->addIcon('4', Aastra_get_custom_icon('Offhook')); } else { # Display error require_once 'AastraIPPhoneTextScreen.class.php'; $object = new AastraIPPhoneTextScreen(); $object->setDestroyOnExit(); if ($lookup == '') { $object->setTitle(Aastra_get_label('Directory error', $language)); $object->setText(Aastra_get_label('Directory list is empty. Please contact your administrator.', $language)); } else { $object->setTitle(Aastra_get_label('Lookup error', $language)); $object->setText(Aastra_get_label('Sorry no match.', $language)); }
} $text = array('firstlast' => Aastra_get_label('First Last', $LANGUAGE), 'lastfirst' => Aastra_get_label('Last First', $LANGUAGE)); $object->addEntry(sprintf(Aastra_get_label('Display: %s', $LANGUAGE), $text[$ARRAY_USER['display']]), $XML_SERVER . '&action=set_display', ''); $text = array('last' => Aastra_get_label('Last Name', $LANGUAGE), 'first' => Aastra_get_label('First Name', $LANGUAGE)); $object->addEntry(sprintf(Aastra_get_label('Sort: %s', $LANGUAGE), $text[$ARRAY_USER['sort']]), $XML_SERVER . '&action=set_sort', ''); # Softkeys if ($nb_softkeys) { if ($nb_softkeys == 6) { $object->addSoftkey('1', Aastra_get_label('Change', $LANGUAGE), 'SoftKey:Select'); $object->addSoftkey('4', Aastra_get_label('Back', $LANGUAGE), $XML_SERVER . '&action=input'); $object->addSoftkey('6', Aastra_get_label('Exit', $LANGUAGE), 'SoftKey:Exit'); } else { $object->addSoftkey('9', Aastra_get_label('Back', $LANGUAGE), $XML_SERVER . '&action=input', 1); $object->addSoftkey('10', Aastra_get_label('Exit', $LANGUAGE), 'SoftKey:Exit', 2); $object->setCancelAction($XML_SERVER . '&action=input'); $object->addIcon(1, 'Icon:ArrowLeft'); $object->addIcon(2, 'Icon:CircleRed'); } } else { $object->addEntry(Aastra_get_label('Back', $LANGUAGE), $XML_SERVER . '&action=input'); $object->setCancelAction($XML_SERVER . '&action=input'); } break; # Change display value # Change display value case 'set_display': # Save value if ($ARRAY_USER['display'] == 'firstlast') { $ARRAY_USER['display'] = 'lastfirst'; } else { $ARRAY_USER['display'] = 'firstlast';
$object->addSoftkey('9', Aastra_get_label('Other Keys', $language), $XML_SERVER . '&action=select&type=' . $type . '&set=' . $set); } $object->addSoftkey('10', Aastra_get_label('Exit', $language), 'SoftKey:Exit'); } } else { # Non softkey phones if ($otherkeys) { $object->addEntry(Aastra_get_label('Other Keys', $language), $XML_SERVER . '&action=select&type=' . $type . '&page=' . $page . '&set=' . $set); } if ($page != $last) { $object->addEntry(Aastra_get_label('Next Page', $language), $XML_SERVER . '&type=' . $type . '&page=' . ($page + 1) . '&set=' . $set); } } } # Icons if ($is_icons) { if (Aastra_phone_type() != 5) { $object->addIcon(1, '3E4E4A4E3E00'); $object->addIcon(2, '4E8E8A8E7E00'); $object->addIcon(3, '32167C163200'); } else { $object->addIcon(1, 'Icon:Lock'); $object->addIcon(2, 'Icon:UnLock'); $object->addIcon(3, 'Icon:World'); } } break; } # Display object $object->output(); exit;