Changeset 6170

Show
Ignore:
Timestamp:
07/24/08 18:21:08 (4 months ago)
Author:
p_lindheimer
Message:

closes #2068 use recording_ids, adds queues_ivr_usage for #2948, don't list IVR's with compound recordings and don't list compound recordigns for announcement message

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • modules/branches/2.5/queues/functions.inc.php

    r5993 r6170  
    144144        } else { 
    145145                return false; 
     146        } 
     147} 
     148 
     149function queues_recordings_usage($recording_id) { 
     150        global $active_modules; 
     151 
     152        $results = sql("SELECT `extension`, `descr` FROM `queues_config` WHERE `agentannounce_id` = '$recording_id' OR `joinannounce_id` = '$recording_id'","getAll",DB_FETCHMODE_ASSOC); 
     153        if (empty($results)) { 
     154                return array(); 
     155        } else { 
     156                //$type = isset($active_modules['queues']['type'])?$active_modules['queues']['type']:'setup'; 
     157                foreach ($results as $result) { 
     158                        $usage_arr[] = array( 
     159                          'url_query' => 'config.php?display=queues&extdisplay='.urlencode($result['extension']), 
     160                                'description' => "Queue: ".$result['descr'], 
     161                        ); 
     162                } 
     163                return $usage_arr; 
     164        } 
     165} 
     166 
     167function queues_ivr_usage($ivr_id) { 
     168        global $active_modules; 
     169 
     170        $results = sql("SELECT `extension`, `descr` FROM `queues_config` WHERE `ivr_id` = '$ivr_id'","getAll",DB_FETCHMODE_ASSOC); 
     171        if (empty($results)) { 
     172                return array(); 
     173        } else { 
     174                foreach ($results as $result) { 
     175                        $usage_arr[] = array( 
     176                          'url_query' => 'config.php?display=queues&extdisplay='.urlencode($result['extension']), 
     177                                'description' => "Queue: ".$result['descr'], 
     178                        ); 
     179                } 
     180                return $usage_arr; 
    146181        } 
    147182} 
     
    208243 
    209244                                        $ext->add('ext-queues', $exten, '', new ext_setvar('MONITOR_FILENAME','/var/spool/asterisk/monitor/q${EXTEN}-${STRFTIME(${EPOCH},,%Y%m%d-%H%M%S)}-${UNIQUEID}')); 
    210                                         $joinannounce = (isset($q['joinannounce'])?$q['joinannounce']:''); 
    211                                         if($joinannounce != "") { 
     245                                        $joinannounce_id = (isset($q['joinannounce_id'])?$q['joinannounce_id']:''); 
     246                                        if($joinannounce_id) { 
     247                                                $joinannounce = recordings_get_file($joinannounce_id); 
    212248                                                $ext->add('ext-queues', $exten, '', new ext_playback($joinannounce)); 
    213249                                        } 
     
    223259                                                $ext->add('ext-queues', $exten, '', new ext_setvar('_CWIGNORE', 'TRUE')); 
    224260                                        } 
    225                                         $agentannounce = (isset($q['agentannounce'])?$q['agentannounce']:''); 
     261                                        $agentannounce_id = (isset($q['agentannounce_id'])?$q['agentannounce_id']:''); 
     262                                        if ($agentannounce_id) { 
     263                                                $agentannounce = recordings_get_file($agentannounce_id); 
     264                                        } else { 
     265                                                $agentannounce = ''; 
     266                                        } 
    226267                                        $ext->add('ext-queues', $exten, '', new ext_queue($exten,$options,'',$agentannounce,$q['maxwait'])); 
    227268  
     
    276317} 
    277318 
    278 function queues_add($account,$name,$password,$prefix,$goto,$agentannounce,$members,$joinannounce,$maxwait,$alertinfo='',$cwignore='no',$qregex='') { 
     319function queues_add($account,$name,$password,$prefix,$goto,$agentannounce_id,$members,$joinannounce_id,$maxwait,$alertinfo='',$cwignore='no',$qregex='') { 
    279320        global $db; 
    280321 
     
    285326 
    286327        //add to extensions table 
    287         if (empty($agentannounce) || $agentannounce == 'None') { 
    288                 $agentannounce=""; 
     328        if (empty($agentannounce_id)) { 
     329                $agentannounce_id=""; 
    289330        } 
    290331 
     
    333374        $grppre        = isset($prefix) ? addslashes($prefix):''; 
    334375        $alertinfo     = isset($alertinfo) ? addslashes($alertinfo):''; 
    335         $joinannounce  = strtolower($joinannounce) != 'none' ? $joinannounce:''
     376        //$joinannounce_id  = $joinannounce_id
    336377        $ringing       = isset($_REQUEST['rtone']) ? $_REQUEST['rtone']:''; 
    337         $agentannounce = strtolower($agentannounce) != 'none' ? $agentannounce:''
     378        //$agentannounce_id = $agentannounce_id
    338379        $maxwait       = isset($maxwait) ? $maxwait:''; 
    339380        $password      = isset($password) ? $password:''; 
     
    344385 
    345386        // Assumes it has just been deleted 
    346         $sql = "INSERT INTO queues_config (extension, descr, grppre, alertinfo, joinannounce, ringing, agentannounce, maxwait, password, ivr_id, dest, cwignore, qregex) 
    347                 VALUES ('$extension', '$descr', '$grppre', '$alertinfo', '$joinannounce', '$ringing', '$agentannounce', '$maxwait', '$password', '$ivr_id', '$dest', '$cwignore', '$qregex')  "; 
     387        $sql = "INSERT INTO queues_config (extension, descr, grppre, alertinfo, joinannounce_id, ringing, agentannounce_id, maxwait, password, ivr_id, dest, cwignore, qregex) 
     388                VALUES ('$extension', '$descr', '$grppre', '$alertinfo', '$joinannounce_id', '$ringing', '$agentannounce_id', '$maxwait', '$password', '$ivr_id', '$dest', '$cwignore', '$qregex')    "; 
    348389        $results = sql($sql); 
    349390        return true; 
     
    445486 
    446487        $compound_recordings = array(); 
    447         $sql = "SELECT extension, descr, agentannounce, ivr_id FROM queues_config WHERE (ivr_id != 'none' AND ivr_id != '') OR agentannounce != ''"; 
     488        $sql = "SELECT extension, descr, agentannounce_id, ivr_id FROM queues_config WHERE (ivr_id != 'none' AND ivr_id != '') OR agentannounce_id != ''"; 
    448489        $results = sql($sql, "getAll",DB_FETCHMODE_ASSOC); 
    449490 
     
    459500 
    460501        foreach ($results as $result) { 
    461                 if (strpos($result['agentannounce'],"&") !== false) { 
     502                $agentannounce = $result['agentannounce_id'] ? recordings_get_file($result['agentannounce_id']):''; 
     503                if (strpos($agentannounce,"&") !== false) { 
    462504                        $compound_recordings[] = array( 
    463505                                                        'extension' => $result['extension'], 
     
    467509                } 
    468510                if ($result['ivr_id'] != 'none' && $result['ivr_id'] != '' && $check_ivr) { 
    469                         if (strpos($ivr_hash[$result['ivr_id']]['announcement'],"&") !== false) { 
     511                        $id = $ivr_hash[$result['ivr_id']]['announcement_id']; 
     512                        $announce = $id ? recordings_get_file($id) : ''; 
     513                        if (strpos($announce,"&") !== false) { 
    470514                                $compound_recordings[] = array( 
    471515                                                                'extension' => $result['extension'], 
     
    526570                // We need to strip off all but the first sound file of any compound sound files 
    527571                // 
    528                 $agentannounce_arr        = explode("&", $config['agentannounce']); 
    529                 $results['agentannounce'] = $agentannounce_arr[0]; 
     572                $agentannounce_id_arr        = explode("&", $config['agentannounce_id']); 
     573                $results['agentannounce_id'] = $agentannounce_id_arr[0]; 
    530574        } else { 
    531575                $sql = "SELECT * FROM queues_config WHERE extension = $account"; 
     
    534578                $results['prefix']        = $config['grppre']; 
    535579                $results['alertinfo']     = $config['alertinfo']; 
    536                 $results['agentannounce'] = $config['agentannounce']; 
     580                $results['agentannounce_id'] = $config['agentannounce_id']; 
    537581                $results['maxwait']       = $config['maxwait']; 
    538582                $results['name']          = $config['descr']; 
    539                 $results['joinannounce']  = $config['joinannounce']; 
     583                $results['joinannounce_id']  = $config['joinannounce_id']; 
    540584                $results['password']      = $config['password']; 
    541585                $results['goto']          = $config['dest']; 
  • modules/branches/2.5/queues/install.php

    r5949 r6170  
    301301        } 
    302302 
    303  
    304  
    305  
    306303        // Version 2.5 upgrade 
    307304        outn(_("checking for qregex field..")); 
     
    320317        } 
    321318 
     319// Version 2.5 migrate to recording ids 
     320// Note: we purposely did not chnage the inital creation of the 
     321//       recording ids as it is safer with all the complex 
     322//       migration code to simply stick with what works and 
     323//       then convert it here even if new. 
     324// 
     325outn(_("Checking if recordings need migration..")); 
     326$sql = "SELECT agentannounce_id FROM queues_config"; 
     327$check = $db->getRow($sql, DB_FETCHMODE_ASSOC); 
     328if(DB::IsError($check)) { 
     329        //  Add recording_id field 
     330        // 
     331        out("migrating"); 
     332        outn(_("adding agentannounce_id field..")); 
     333  $sql = "ALTER TABLE queues_config ADD agentannounce_id INTEGER"; 
     334  $result = $db->query($sql); 
     335  if(DB::IsError($result)) { 
     336                out(_("fatal error")); 
     337                die_freepbx($result->getDebugInfo());  
     338        } else { 
     339                out(_("ok")); 
     340        } 
     341        outn(_("adding joinannounce_id field..")); 
     342  $sql = "ALTER TABLE queues_config ADD joinannounce_id INTEGER"; 
     343  $result = $db->query($sql); 
     344  if(DB::IsError($result)) { 
     345                out(_("fatal error")); 
     346                die_freepbx($result->getDebugInfo());  
     347        } else { 
     348                out(_("ok")); 
     349        } 
     350 
     351        // Get all the valudes and replace them with recording_id 
     352        // 
     353        outn(_("migrate agentannounce to ids..")); 
     354  $sql = "SELECT `extension`, `agentannounce` FROM `queues_config`"; 
     355        $results = $db->getAll($sql, DB_FETCHMODE_ASSOC); 
     356        if(DB::IsError($results)) { 
     357                out(_("fatal error")); 
     358                die_freepbx($results->getDebugInfo());   
     359        } 
     360        $migrate_arr = array(); 
     361        $count = 0; 
     362        foreach ($results as $row) { 
     363                if (trim($row['agentannounce']) != '') { 
     364                        $rec_id = recordings_get_or_create_id($row['agentannounce'], 'queues'); 
     365                        $migrate_arr[] = array($rec_id, $row['extension']); 
     366                        $count++; 
     367                } 
     368        } 
     369        if ($count) { 
     370                $compiled = $db->prepare('UPDATE `queues_config` SET `agentannounce_id` = ? WHERE `extension` = ?'); 
     371                $result = $db->executeMultiple($compiled,$migrate_arr); 
     372                if(DB::IsError($result)) { 
     373                        out(_("fatal error")); 
     374                        die_freepbx($result->getDebugInfo());    
     375                } 
     376        } 
     377        out(sprintf(_("migrated %s entries"),$count)); 
     378 
     379        outn(_("migrate joinannounce to ids..")); 
     380  $sql = "SELECT `extension`, `joinannounce` FROM `queues_config`"; 
     381        $results = $db->getAll($sql, DB_FETCHMODE_ASSOC); 
     382        if(DB::IsError($results)) { 
     383                out(_("fatal error")); 
     384                die_freepbx($results->getDebugInfo());   
     385        } 
     386        $migrate_arr = array(); 
     387        $count = 0; 
     388        foreach ($results as $row) { 
     389                if (trim($row['joinannounce']) != '') { 
     390                        $rec_id = recordings_get_or_create_id($row['joinannounce'], 'queues'); 
     391                        $migrate_arr[] = array($rec_id, $row['extension']); 
     392                        $count++; 
     393                } 
     394        } 
     395        if ($count) { 
     396                $compiled = $db->prepare('UPDATE `queues_config` SET `joinannounce_id` = ? WHERE `extension` = ?'); 
     397                $result = $db->executeMultiple($compiled,$migrate_arr); 
     398                if(DB::IsError($result)) { 
     399                        out(_("fatal error")); 
     400                        die_freepbx($result->getDebugInfo());    
     401                } 
     402        } 
     403        out(sprintf(_("migrated %s entries"),$count)); 
     404 
     405        // Now remove the old recording field replaced by new id field 
     406        // 
     407        outn(_("dropping agentannounce field..")); 
     408  $sql = "ALTER TABLE `queues_config` DROP `agentannounce`"; 
     409  $result = $db->query($sql); 
     410  if(DB::IsError($result)) {  
     411                out(_("no agentannounce field???")); 
     412        } else { 
     413                out(_("ok")); 
     414        } 
     415        outn(_("dropping joinannounce field..")); 
     416  $sql = "ALTER TABLE `queues_config` DROP `joinannounce`"; 
     417  $result = $db->query($sql); 
     418  if(DB::IsError($result)) {  
     419                out(_("no joinannounce field???")); 
     420        } else { 
     421                out(_("ok")); 
     422        } 
     423} else { 
     424        out("already migrated"); 
     425} 
     426 
    322427?> 
  • modules/branches/2.5/queues/module.xml

    r6097 r6170  
    22        <rawname>queues</rawname> 
    33        <name>Queues</name> 
    4         <version>2.5.0.1</version> 
     4        <version>2.5.1</version> 
    55        <type>setup</type> 
    66        <category>Inbound Call Control</category> 
     
    99        </description> 
    1010        <changelog> 
     11                *2.5.1* #2068 recordings_id, don't list IVRs with compound messages 
    1112                *2.5.0.1* #2875, #2768 
    1213                *2.5.0.0* #2976 Add Optional Regex to filter user agent numbers that they can input 
     
    4849        <depends> 
    4950                <version>2.5.0alpha1</version> 
     51                <module>recordings ge 3.3.8</module> 
    5052        </depends> 
    5153        <menuitems> 
  • modules/branches/2.5/queues/page.queues.php

    r6163 r6170  
    2121isset($_REQUEST['name'])?$name = $_REQUEST['name']:$name=''; 
    2222isset($_REQUEST['password'])?$password = $_REQUEST['password']:$password=''; 
    23 isset($_REQUEST['agentannounce'])?$agentannounce = $_REQUEST['agentannounce']:$agentannounce=''; 
     23isset($_REQUEST['agentannounce_id'])?$agentannounce_id = $_REQUEST['agentannounce_id']:$agentannounce_id=''; 
    2424isset($_REQUEST['prefix'])?$prefix = $_REQUEST['prefix']:$prefix=''; 
    2525isset($_REQUEST['alertinfo'])?$alertinfo = $_REQUEST['alertinfo']:$alertinfo=''; 
    26 isset($_REQUEST['joinannounce'])?$joinannounce = $_REQUEST['joinannounce']:$joinannounce=''; 
     26isset($_REQUEST['joinannounce_id'])?$joinannounce_id = $_REQUEST['joinannounce_id']:$joinannounce_id=''; 
    2727$maxwait = isset($_REQUEST['maxwait'])?$_REQUEST['maxwait']:''; 
    2828$cwignore = isset($_REQUEST['cwignore'])?$_REQUEST['cwignore']:'0'; 
     
    9898                                        $conflict_url = framework_display_extension_usage_alert($usage_arr); 
    9999                                } else { 
    100                                         queues_add($account,$name,$password,$prefix,$goto,$agentannounce,$members,$joinannounce,$maxwait,$alertinfo,$cwignore,$qregex); 
     100                                        queues_add($account,$name,$password,$prefix,$goto,$agentannounce_id,$members,$joinannounce_id,$maxwait,$alertinfo,$cwignore,$qregex); 
    101101                                        needreload(); 
    102102                                        redirect_standard(); 
     
    110110                        case "edit":  //just delete and re-add 
    111111                                queues_del($account); 
    112                                 queues_add($account,$name,$password,$prefix,$goto,$agentannounce,$members,$joinannounce,$maxwait,$alertinfo,$cwignore,$qregex); 
     112                                queues_add($account,$name,$password,$prefix,$goto,$agentannounce_id,$members,$joinannounce_id,$maxwait,$alertinfo,$cwignore,$qregex); 
    113113                                needreload(); 
    114114                                redirect_standard('extdisplay'); 
     
    244244                <td><a href="#" class="info"><?php echo _("Agent Announcement:")?><span><?php echo _("Announcement played to the Agent prior to bridging in the caller <br><br> Example: \"the Following call is from the Sales Queue\" or \"This call is from the Technical Support Queue\".<br><br>To add additional recordings please use the \"System Recordings\" MENU to the left. Compound recordings composed of 2 or more sound files are not displayed as options since this feature can not accept such recordings.")?></span></a></td> 
    245245                <td> 
    246                         <select name="agentannounce" tabindex="<?php echo ++$tabindex;?>"> 
     246                        <select name="agentannounce_id" tabindex="<?php echo ++$tabindex;?>"> 
    247247                        <?php 
    248248                                $tresults = recordings_list(false); 
    249                                 $default = (isset($agentannounce) ? $agentannounce : 'None'); 
    250  
    251                                 echo '<option value="None">'._("None").'</option>'; 
     249                                $default = (isset($agentannounce_id) ? $agentannounce_id : ''); 
     250 
     251                                echo '<option value="">'._("None").'</option>'; 
    252252                                if (isset($tresults[0])) { 
    253253                                        foreach ($tresults as $tresult) { 
    254                                                 echo '<option value="'.$tresult[2].'" '.($tresult[2] == $default ? 'SELECTED' : '').'>'.$tresult[1]."</option>\n";
     254                                                echo '<option value="'.$tresult['id'].'"'.($tresult['id'] == $default ? ' SELECTED' : '').'>'.$tresult['displayname']."</option>\n"
    255255                                        } 
    256256                                } 
     
    264264                <td> 
    265265                        <?php 
    266                                 $default = (isset($agentannounce) ? $agentannounce : ''); 
     266                                $default = (isset($agentannounce_id) ? $agentannounce_id : ''); 
    267267                        ?> 
    268                         <input type="hidden" name="agentannounce" value="<?php echo $default; ?>"><?php echo ($default != '' ? $default : 'None'); ?> 
    269                 </td> 
    270         </tr> 
    271 <?php } ?> 
    272  
    273 <?php if(function_exists('music_list')) { //only include if music module is enabled?> 
     268                        <input type="hidden" name="agentannounce_id" value="<?php echo $default; ?>"><?php echo ($default != '' ? $default : ''); ?> 
     269                </td> 
     270        </tr> 
     271<?php  
     272        } 
     273if(function_exists('recordings_list')) { //only include if recordings is enabled ?> 
     274        <tr> 
     275                <td><a href="#" class="info"><?php echo _("Join Announcement:")?><span><?php echo _("Announcement played to callers once prior to joining the queue.<br><br>To add additional recordings please use the \"System Recordings\" MENU to the left")?></span></a></td> 
     276                <td> 
     277                        <select name="joinannounce_id" tabindex="<?php echo ++$tabindex;?>"> 
     278                        <?php 
     279                                $tresults = recordings_list(); 
     280                                $default = (isset($joinannounce_id) ? $joinannounce_id : ''); 
     281                                echo '<option value="None">'._("None"); 
     282                                if (isset($tresults[0])) { 
     283                                        foreach ($tresults as $tresult) { 
     284                                                echo '<option value="'.$tresult['id'].'"'.($tresult['id'] == $default ? ' SELECTED' : '').'>'.$tresult['displayname']."</option>\n"; 
     285                                        } 
     286                                } 
     287                        ?>               
     288                        </select>                
     289                </td> 
     290        </tr> 
     291<?php } else { ?> 
     292        <tr> 
     293                <td><a href="#" class="info"><?php echo _("Join Announcement:")?><span><?php echo _("Announcement played to callers once prior to joining the queue.<br><br>You must install and enable the \"Systems Recordings\" Module to edit this option")?></span></a></td> 
     294                <td> 
     295                        <?php 
     296                                $default = (isset($joinannounce_id) ? $joinannounce_id : ''); 
     297                        ?> 
     298                        <input type="hidden" name="joinannounce_id" value="<?php echo $default; ?>"><?php echo ($default != '' ? $default : ''); ?> 
     299                </td> 
     300        </tr> 
     301<?php  
     302
     303 
     304if(function_exists('music_list')) { //only include if music module is enabled?> 
    274305        <tr> 
    275306                <td><a href="#" class="info"><?php echo _("Music on Hold Class:")?><span><?php echo _("Music (or Commercial) played to the caller while they wait in line for an available agent. Choose \"inherit\" if you want the MoH class to be what is currently selected, such as by the inbound route.<br><br>  This music is defined in the \"Music on Hold\" Menu to the left.")?></span></a></td> 
     
    559590                         
    560591                        //query for exisiting aa_N contexts 
     592                        // 
     593                        // If a previous bogus IVR was listed, we will leave it in with an error but will no longer show such IVRs as valid options. 
    561594                        $unique_aas = ivr_list();                
    562595                         
     
    571604                                        if (strpos($unique_aa['announcement'],"&") === false) { 
    572605                                                echo '<option value="'.$menu_id.'" '.($default == $menu_id ? 'SELECTED' : '').'>'.($menu_name ? $menu_name : _("Menu ID ").$menu_id)."</option>\n"; 
    573                                         } else { 
     606                                        }  
     607                                        else { 
    574608                                                $compound_recordings = true; 
    575                                                 echo '<option style="color:red" value="'.$menu_id.'" '.($default == $menu_id ? 'SELECTED' : '').'>'.($menu_name ? $menu_name : _("Menu ID ").$menu_id)." (**)</option>\n"; 
    576609                                                if ($menu_id == $default) { 
     610                                                        echo '<option style="color:red" value="'.$menu_id.'" '.($default == $menu_id ? 'SELECTED' : '').'>'.($menu_name ? $menu_name : _("Menu ID ").$menu_id)." (**)</option>\n"; 
    577611                                                        $is_error = true; 
    578612                                                } 
     
    583617                        </select> 
    584618                        <?php 
    585                         if ($compound_recordings) { 
     619                        if ($is_error) { 
    586620                        ?> 
    587621                                <small><a style="color:red"  href="#" class="info"><?php echo ($is_error ? _("(**) ERRORS") : _("(**) Warning Potential Errors"))?> 
     
    589623                                                <?php  
    590624                                                        if ($is_error) { 
    591                                                                 echo _("ERROR: You have selected an IVR's that use Announcements created from compound sound files. The Queue is not able to play these announcements. This IVR's recording will be truncated to use only the first sound file. You can correct the problem by selecting a different annoucement for this IVR that is not from a compound sound file. The IVR itself can play such files, but the Queue subsystem can not"); 
    592                                                         } else { 
    593                                                                 echo _("You have IVR's that use Announcements created from compound sound files. The Queue is not able to play these announcements. If you choose one of these the recording used with be truncated to use only the first sound file. You can choose this IVR now and then correct the problem by selecting a different annoucement for your IVR that is not from a compound sound file. The IVR itself can play such files, but the Queue subsystem can not"); 
     625                                                                echo _("ERROR: You have selected an IVR's that use Announcements created from compound sound files. The Queue is not able to play these announcements. This IVR's recording will be truncated to use only the first sound file. You can correct the problem by selecting a different annoucement for this IVR that is not from a compound sound file. The IVR itself can play such files, but the Queue subsystem can not").'<br />'._("Earlier versions of this module allowed such queues to be chosen, once changing this setting, it will no longer appear as an option"); 
    594626                                                        } 
    595627                                                ?> 
     
    619651<?php } else { 
    620652        echo "<input type=\"hidden\" name=\"announcemenu\" value=\"none\">"; 
    621 
    622  
    623 if(function_exists('recordings_list')) { //only include if recordings is enabled ?> 
    624         <tr> 
    625                 <td><a href="#" class="info"><?php echo _("Join Announcement:")?><span><?php echo _("Announcement played to callers once prior to joining the queue.<br><br>To add additional recordings please use the \"System Recordings\" MENU to the left")?></span></a></td> 
    626                 <td> 
    627                         <select name="joinannounce" tabindex="<?php echo ++$tabindex;?>"> 
    628                         <?php 
    629                                 $tresults = recordings_list(); 
    630                                 $default = (isset($joinannounce) ? $joinannounce : 'None'); 
    631                                 echo '<option value="None">'._("None"); 
    632                                 if (isset($tresults[0])) { 
    633                                         foreach ($tresults as $tresult) { 
    634                                                 echo '<option value="'.$tresult[2].'" '.($tresult[2] == $default ? 'SELECTED' : '').'>'.$tresult[1]."</option>\n";; 
    635                                         } 
    636                                 } 
    637                         ?>               
    638                         </select>                
    639                 </td> 
    640         </tr> 
    641 <?php } else { ?> 
    642         <tr> 
    643                 <td><a href="#" class="info"><?php echo _("Join Announcement:")?><span><?php echo _("Announcement played to callers once prior to joining the queue.<br><br>You must install and enable the \"Systems Recordings\" Module to edit this option")?></span></a></td> 
    644                 <td> 
    645                         <?php 
    646                                 $default = (isset($joinannounce) ? $joinannounce : ''); 
    647                         ?> 
    648                         <input type="hidden" name="joinannounce" value="<?php echo $default; ?>"><?php echo ($default != '' ? $default : 'None'); ?> 
    649                 </td> 
    650         </tr> 
    651 <?php } ?> 
    652 <?php 
     653        } 
    653654        // implementation of module hook 
    654655        // object was initialized in config.php 
Donate



Support
Download
Develop
Forums
News
Documentation
Paid Support
About

Paid Ads