Changeset 970

Show
Ignore:
Timestamp:
02/23/06 03:53:38 (3 years ago)
Author:
qldrob
Message:

Fixed ringgroups, and a couple more warning cleanups.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/AMP/amp_conf/htdocs/admin/modules/conferences/functions.inc.php

    r934 r970  
    8181        foreach($results as $result){ 
    8282                // check to see if we are in-range for the current AMP User. 
    83                 if (checkRange($result[0])){ 
     83                if (isset($result[0]) && checkRange($result[0])){ 
    8484                        // return this item's dialplan destination, and the description 
    8585                        $extens[] = array($result['exten'],$result['description']); 
  • trunk/AMP/amp_conf/htdocs/admin/modules/ringgroups/functions.inc.php

    r963 r970  
    8383           die($res->getMessage()); 
    8484        } 
    85         if (preg_match("/^rg-group,(.*),(.*),(.*),(.*)$/", $res[0][0], $matches)) { 
     85        if (isset($res[0][0]) && preg_match("/^rg-group,(.*),(.*),(.*),(.*)$/", $res[0][0], $matches)) { 
    8686                $strategy = $matches[1]; 
    8787                $time = $matches[2]; 
  • trunk/AMP/amp_conf/htdocs/admin/modules/ringgroups/page.ringgroups.php

    r942 r970  
    2929 
    3030 
    31 $grplist = array(); 
    3231if (isset($_REQUEST["grplist"])) { 
    3332        $grplist = explode("\n",$_REQUEST["grplist"]); 
    3433 
    3534        if (!$grplist) { 
    36                 $grplist = array()
     35                $grplist = null
    3736        } 
    3837         
     
    130129                        <tr><td colspan="2"><h5><?php  echo ($extdisplay ? _("Edit Ring Group") : _("Add Ring Group")) ?><hr></h5></td></tr> 
    131130                        <tr> 
    132 <?php           if ($extdisplay){ ?> 
     131<?php 
     132        if ($extdisplay) {  
     133                // We need to populate grplist with the existing extension list. 
     134                ringgroups_get(ltrim($extdisplay,'GRP-'), $strategy,  $grptime, $grppre, $grpliststr); 
     135                $grplist=explode("-", $grpliststr); 
     136 
     137 
     138?> 
    133139                                <input size="5" type="hidden" name="account" value="<?php  echo ltrim($extdisplay,'GRP-'); ?>"> 
    134140<?php           } else { ?> 
     
    160166                                <td valign="top"><a href="#" class="info"><?php echo _("extension list")?>:<span><br><?php echo _("List extensions to ring, one per line.<br><br>You can include an extension on a remote system, or an external number by suffixing a number with a pound (#).  ex:  2448089# would dial 2448089 on the appropriate trunk (see Outbound Routing).")?><br><br></span></a></td> 
    161167                                <td valign="top">&nbsp; 
    162                                         <textarea id="grplist" cols="15" rows="<?php  $rows = count($grplist)+1; echo (($rows < 5) ? 5 : (($rows > 20) ? 20 : $rows) ); ?>" name="grplist"><?php echo implode("\n",$grplist);?></textarea><br> 
     168<?php 
     169                $rows = count($grplist)+1;  
     170                ($rows < 5) ? 5 : (($rows > 20) ? 20 : $rows); 
     171?> 
     172                                        <textarea id="grplist" cols="15" rows="<?php  echo $rows ?>" name="grplist"><?php echo implode("\n",$grplist);?></textarea><br> 
    163173                                         
    164174                                        <input type="submit" style="font-size:10px;" value="Clean & Remove duplicates" /> 
Donate



Support
Download
Develop
Forums
News
Documentation
Paid Support
About

Paid Ads