phpgroupware-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Phpgroupware-cvs] CVS: addressbook/inc class.uiaddressbook.inc.php,1.38


From: Miles Lott <address@hidden>
Subject: [Phpgroupware-cvs] CVS: addressbook/inc class.uiaddressbook.inc.php,1.38,1.39 class.boaddressbook.inc.php,1.22,1.23
Date: Wed, 27 Feb 2002 23:23:18 -0500

Update of /cvsroot/phpgroupware/addressbook/inc
In directory subversions:/tmp/cvs-serv19382

Modified Files:
        class.uiaddressbook.inc.php class.boaddressbook.inc.php 
Log Message:
Now using get_var() from api



Index: class.uiaddressbook.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware/addressbook/inc/class.uiaddressbook.inc.php,v
retrieving revision 1.38
retrieving revision 1.39
diff -C2 -r1.38 -r1.39
*** class.uiaddressbook.inc.php 17 Jan 2002 04:02:20 -0000      1.38
--- class.uiaddressbook.inc.php 28 Feb 2002 04:23:16 -0000      1.39
***************
*** 26,30 ****
  
                var $start;
-               var $limit;
                var $query;
                var $sort;
--- 26,29 ----
***************
*** 70,74 ****
                {
                        $this->start    = $this->bo->start;
-                       $this->limit    = $this->bo->limit;
                        $this->query    = $this->bo->query;
                        $this->sort     = $this->bo->sort;
--- 69,72 ----
***************
*** 86,90 ****
                        $data = array(
                                'start'  => $this->start,
-                               'limit'  => $this->limit,
                                'query'  => $this->query,
                                'sort'   => $this->sort,
--- 84,87 ----
***************
*** 102,106 ****
                        $data = array(
                                'start'  => $this->start,
-                               'limit'  => $this->limit,
                                'query'  => $this->query,
                                'sort'   => $this->sort,
--- 99,102 ----
***************
*** 365,373 ****
                                
$GLOBALS['phpgw_info']['user']['preferences']['common']['maxmatchs'] > 0)
                        {
!                               $this->limit = 
$GLOBALS['phpgw_info']['user']['preferences']['common']['maxmatchs'];
                        }
                        else
                        {
!                               $this->limit = 30;
                        }
  
--- 361,369 ----
                                
$GLOBALS['phpgw_info']['user']['preferences']['common']['maxmatchs'] > 0)
                        {
!                               $limit = 
$GLOBALS['phpgw_info']['user']['preferences']['common']['maxmatchs'];
                        }
                        else
                        {
!                               $limit = 30;
                        }
  
***************
*** 426,430 ****
                                $entries = $this->bo->read_entries(array(
                                        'start'  => $this->start,
!                                       'limit'  => $this->limit,
                                        'fields' => $columns_to_display,
                                        'filter' => $qfilter,
--- 422,426 ----
                                $entries = $this->bo->read_entries(array(
                                        'start'  => $this->start,
!                                       'limit'  => $limit,
                                        'fields' => $columns_to_display,
                                        'filter' => $qfilter,
***************
*** 437,447 ****
  
                        /* global here so nextmatchs accepts our setting of 
$query and $filter */
!                       $GLOBALS['query']  = $this->query;
!                       $GLOBALS['filter'] = $this->filter;
  
                        $search_filter = 
$GLOBALS['phpgw']->nextmatchs->show_tpl('/index.php',
                                $this->start, 
$total_records,'&menuaction=addressbook.uiaddressbook.index&fcat_id='.$this->cat_id,'75%',
                                
$GLOBALS['phpgw_info']['theme']['th_bg'],1,1,1,1,$this->cat_id);
!                       $query = $filter = '';
  
                        $lang_showing = 
$GLOBALS['phpgw']->nextmatchs->show_hits($total_records,$this->start);
--- 433,443 ----
  
                        /* global here so nextmatchs accepts our setting of 
$query and $filter */
! //                    $GLOBALS['query']  = $this->query;
! //                    $GLOBALS['filter'] = $this->filter;
  
                        $search_filter = 
$GLOBALS['phpgw']->nextmatchs->show_tpl('/index.php',
                                $this->start, 
$total_records,'&menuaction=addressbook.uiaddressbook.index&fcat_id='.$this->cat_id,'75%',
                                
$GLOBALS['phpgw_info']['theme']['th_bg'],1,1,1,1,$this->cat_id);
! //                    $query = $filter = '';
  
                        $lang_showing = 
$GLOBALS['phpgw']->nextmatchs->show_hits($total_records,$this->start);

Index: class.boaddressbook.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware/addressbook/inc/class.boaddressbook.inc.php,v
retrieving revision 1.22
retrieving revision 1.23
diff -C2 -r1.22 -r1.23
*** class.boaddressbook.inc.php 17 Jan 2002 03:52:55 -0000      1.22
--- class.boaddressbook.inc.php 28 Feb 2002 04:23:16 -0000      1.23
***************
*** 54,58 ****
                var $so;
                var $start;
-               var $limit;
                var $query;
                var $sort;
--- 54,57 ----
***************
*** 75,128 ****
                                $this->use_session = True;
                        }
-                       /* _debug_array($GLOBALS['HTTP_POST_VARS']); */
-                       /* Might change this to '' at the end---> */
-                       $_start   = $GLOBALS['HTTP_POST_VARS']['start']   ? 
$GLOBALS['HTTP_POST_VARS']['start']   : $GLOBALS['HTTP_GET_VARS']['start'];
-                       $_query   = $GLOBALS['HTTP_POST_VARS']['query']   ? 
$GLOBALS['HTTP_POST_VARS']['query']   : $GLOBALS['HTTP_GET_VARS']['query'];
-                       $_sort    = $GLOBALS['HTTP_POST_VARS']['sort']    ? 
$GLOBALS['HTTP_POST_VARS']['sort']    : $GLOBALS['HTTP_GET_VARS']['sort'];
-                       $_order   = $GLOBALS['HTTP_POST_VARS']['order']   ? 
$GLOBALS['HTTP_POST_VARS']['order']   : $GLOBALS['HTTP_GET_VARS']['order'];
-                       $_filter  = $GLOBALS['HTTP_POST_VARS']['filter']  ? 
$GLOBALS['HTTP_POST_VARS']['filter']  : $GLOBALS['HTTP_GET_VARS']['filter'];
-                       $_cat_id  = $GLOBALS['HTTP_POST_VARS']['cat_id']  ? 
$GLOBALS['HTTP_POST_VARS']['cat_id']  : $GLOBALS['HTTP_GET_VARS']['cat_id'];
-                       $_fcat_id = $GLOBALS['HTTP_POST_VARS']['fcat_id'] ? 
$GLOBALS['HTTP_POST_VARS']['fcat_id'] : $GLOBALS['HTTP_GET_VARS']['fcat_id'];
  
!                       if(!empty($_start) || ($_start == '0') || ($_start == 
0))
!                       {
!                               if($this->debug) { echo '<br>overriding $start: 
"' . $this->start . '" now "' . $_start . '"'; }
!                               $this->start = $_start;
!                       }
!                       if($_limit)
!                       {
!                               $this->limit  = $_limit;
!                       }
!                       if((empty($_query) && !empty($this->query)) || 
!empty($_query))
!                       {
!                               $this->query  = $_query;
!                       }
  
!                       if(isset($_fcat_id) && !empty($_fcat_id))
!                       {
!                               $this->cat_id = $_fcat_id;
!                       }
!                       if($_fcat_id == '0' || $_fcat_id == 0 || $_fcat_id == 
'')
!                       {
!                               $this->cat_id = 0;
!                       }
! 
!                       if(isset($_sort)   && !empty($_sort))
!                       {
!                               if($this->debug) { echo '<br>overriding $sort: 
"' . $this->sort . '" now "' . $_sort . '"'; }
!                               $this->sort   = $_sort;
!                       }
! 
!                       if(isset($_order)  && !empty($_order))
!                       {
!                               if($this->debug) { echo '<br>overriding $order: 
"' . $this->order . '" now "' . $_order . '"'; }
!                               $this->order  = $_order;
!                       }
! 
!                       if(isset($_filter) && !empty($_filter))
!                       {
!                               if($this->debug) { echo '<br>overriding 
$filter: "' . $this->filter . '" now "' . $_filter . '"'; }
!                               $this->filter = $_filter;
!                       }
  
                        if($this->debug)
--- 74,93 ----
                                $this->use_session = True;
                        }
  
!                       $start  = get_var('start',   array('POST','GET'));
!                       $query  = get_var('query',   array('POST','GET'));
!                       $sort   = get_var('sort',    array('POST','GET'));
!                       $order  = get_var('order',   array('POST','GET'));
!                       $filter = get_var('filter',  array('POST','GET'));
!                       $cat_id = get_var('fcat_id', array('POST'));
! 
!                       $this->start  = (!empty($start) || ($start == '0')) ? 
$start : $this->start;
!                       $this->query  = (empty($query) && !empty($this->query)) 
|| !empty($query) ? $query : $this->query;
!                       $this->sort   = (!empty($sort)) ? $sort : $this->sort;
!                       $this->order  = (!empty($order)) ? $order : 
$this->order;
!                       $this->filter = (!empty($filter) || ($filter == '0')) ? 
$filter : $this->filter;
  
!                       $this->cat_id = (isset($cat_id) && !empty($cat_id)) ? 
$cat_id : $this->cat_id;
!                       $this->cat_id = ($cat_id == '0' || $cat_id == 0 || 
$cat_id == '') ? $cat_id : $this->cat_id;
  
                        if($this->debug)
***************
*** 136,140 ****
                        $data = array(
                                'start'  => $this->start,
-                               'limit'  => $this->limit,
                                'query'  => $this->query,
                                'sort'   => $this->sort,
--- 101,104 ----
***************
*** 225,229 ****
  
                        $this->start  = $data['start'];
-                       $this->limit  = $data['limit'];
                        $this->query  = $data['query'];
                        $this->sort   = $data['sort'];
--- 189,192 ----
***************
*** 242,246 ****
                        for($i=0;$i<count($dirty);$i++)
                        {
!                               if(gettype($dirty[$i]) == 'array')
                                {
                                        while(list($name,$value) = 
@each($dirty[$i]))
--- 205,209 ----
                        for($i=0;$i<count($dirty);$i++)
                        {
!                               if(is_array($dirty[$i]))
                                {
                                        while(list($name,$value) = 
@each($dirty[$i]))
***************
*** 282,286 ****
                function add_vcard()
                {
!                       global $uploadedfile;
  
                        if($uploadedfile == 'none' || $uploadedfile == '')
--- 245,249 ----
                function add_vcard()
                {
!                       $uploadedfile = 
$GLOBALS['HTTP_POST_VARS']['uploadedfile'];
  
                        if($uploadedfile == 'none' || $uploadedfile == '')
***************
*** 323,327 ****
                function add_email()
                {
!                       global $name,$referer;
  
                        $named = explode(' ', $name);
--- 286,291 ----
                function add_email()
                {
!                       $name    = $GLOBALS['HTTP_GET_VARS']['name'];
!                       $referer = $GLOBALS['HTTP_GET_VARS']['referer'];
  
                        $named = explode(' ', $name);
***************
*** 394,398 ****
                        {
                                
$GLOBALS['phpgw']->preferences->delete('addressbook','mainscreen_showbirthdays');
!                               if($other['mainscreen_showbirthdays'])
                                {
                                        
$GLOBALS['phpgw']->preferences->add('addressbook','mainscreen_showbirthdays',True);
--- 358,362 ----
                        {
                                
$GLOBALS['phpgw']->preferences->delete('addressbook','mainscreen_showbirthdays');
!                               if($other['mainscreen_showbirthdays'])
                                {
                                        
$GLOBALS['phpgw']->preferences->add('addressbook','mainscreen_showbirthdays',True);
***************
*** 400,404 ****
  
                                
$GLOBALS['phpgw']->preferences->delete('addressbook','default_filter');
!                               if($other['default_filter'])
                                {
                                        
$GLOBALS['phpgw']->preferences->add('addressbook','default_filter',True);
--- 364,368 ----
  
                                
$GLOBALS['phpgw']->preferences->delete('addressbook','default_filter');
!                               if($other['default_filter'])
                                {
                                        
$GLOBALS['phpgw']->preferences->add('addressbook','default_filter',True);
***************
*** 406,410 ****
  
                                
$GLOBALS['phpgw']->preferences->delete('addressbook','autosave_category');
!                               if($other['autosave_category'])
                                {
                                        
$GLOBALS['phpgw']->preferences->add('addressbook','autosave_category',True);
--- 370,374 ----
  
                                
$GLOBALS['phpgw']->preferences->delete('addressbook','autosave_category');
!                               if($other['autosave_category'])
                                {
                                        
$GLOBALS['phpgw']->preferences->add('addressbook','autosave_category',True);




reply via email to

[Prev in Thread] Current Thread [Next in Thread]