phpgroupware-cvs
[Top][All Lists]
Advanced

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

[Phpgroupware-cvs] calendar/inc class.boholiday.inc.php, 1.10.2.2.2.1, 1


From: Mark A Peters <address@hidden>
Subject: [Phpgroupware-cvs] calendar/inc class.boholiday.inc.php, 1.10.2.2.2.1, 1.10.2.2.2.2
Date: Sat, 04 Oct 2003 12:11:59 +0000

Update of /cvsroot/phpgroupware/calendar/inc
In directory subversions:/tmp/cvs-serv5682

Modified Files:
      Tag: Version-0_9_16-branch
        class.boholiday.inc.php 
Log Message:
Fixed references to HTTP_POST/GET_VARS.

Index: class.boholiday.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware/calendar/inc/class.boholiday.inc.php,v
retrieving revision 1.10.2.2.2.1
retrieving revision 1.10.2.2.2.2
diff -C2 -d -r1.10.2.2.2.1 -r1.10.2.2.2.2
*** class.boholiday.inc.php     13 Jun 2003 09:15:33 -0000      1.10.2.2.2.1
--- class.boholiday.inc.php     4 Oct 2003 12:11:55 -0000       1.10.2.2.2.2
***************
*** 47,62 ****
                function boholiday()
                {
!                       $this->so = CreateObject('calendar.soholiday');
! 
!                       if(isset($GLOBALS['start']))  { $this->start = 
intval($GLOBALS['start']); } else { $this->start = 0; }
! 
!                       if(isset($GLOBALS['query']))  { $this->query = 
$GLOBALS['query'];      }
! 
!                       if(isset($GLOBALS['sort']))   { $this->sort = 
$GLOBALS['sort'];        }
! 
!                       if(isset($GLOBALS['order']))  { $this->order = 
$GLOBALS['order'];      }
! 
!                       $this->id   = get_var('id',array('POST','GET'));
!                       $this->year = 
get_var('year',array('POST','GET'),date('Y'));
                        $this->locale = get_var('locale',array('POST','GET'));
                        if ($this->locale)
--- 47,57 ----
                function boholiday()
                {
!                       $this->so     = CreateObject('calendar.soholiday');
!                       $this->start  = 
get_var('start',Array('POST','GET','DEFAULT'),0);
!                       $this->query  = get_var('query',Array('POST','GET'));
!                       $this->sort   = get_var('sort',Array('POST','GET'));
!                       $this->order  = get_var('order',Array('POST','GET'));
!                       $this->id     = get_var('id',array('POST','GET'));
!                       $this->year   = 
get_var('year',array('POST','GET','DEFAULT'),date('Y'));
                        $this->locale = get_var('locale',array('POST','GET'));
                        if ($this->locale)
***************
*** 138,142 ****
                function accept_holiday()
                {
!                       $send_back_to = 
str_replace('submitlocale','holiday_admin',$GLOBALS['HTTP_REFERER']);
                        if(address@hidden>locales[0])
                        {
--- 133,137 ----
                function accept_holiday()
                {
!                       $send_back_to = 
str_replace('submitlocale','holiday_admin',$_SERVER['HTTP_REFERER']);
                        if(address@hidden>locales[0])
                        {
***************
*** 146,156 ****
                        $send_back_to = 
str_replace('&locale='.$this->locales[0],'',$send_back_to);
                        $file = './holidays.'.$this->locales[0];
!                       if(!file_exists($file) && 
count($GLOBALS['HTTP_POST_VARS']['name']))
                        {
!                               $c_holidays = 
count($GLOBALS['HTTP_POST_VARS']['name']);
                                $fp = fopen($file,'w');
                                for($i=0;$i<$c_holidays;$i++)
                                {
!                                       
fwrite($fp,$this->locales[0]."\t".$GLOBALS['HTTP_POST_VARS']['name'][$i]."\t".$GLOBALS['HTTP_POST_VARS']['day'][$i]."\t".$GLOBALS['HTTP_POST_VARS']['month'][$i]."\t".$GLOBALS['HTTP_POST_VARS']['occurence'][$i]."\t".$GLOBALS['HTTP_POST_VARS']['dow'][$i]."\t".$GLOBALS['HTTP_POST_VARS']['observance'][$i]."\n");
                                }
                                fclose($fp);
--- 141,151 ----
                        $send_back_to = 
str_replace('&locale='.$this->locales[0],'',$send_back_to);
                        $file = './holidays.'.$this->locales[0];
!                       if(!file_exists($file) && count($_POST['name']))
                        {
!                               $c_holidays = count($_POST['name']);
                                $fp = fopen($file,'w');
                                for($i=0;$i<$c_holidays;$i++)
                                {
!                                       
fwrite($fp,$this->locales[0]."\t".$_POST['name'][$i]."\t".$_POST['day'][$i]."\t".$_POST['month'][$i]."\t".$_POST['occurence'][$i]."\t".$_POST['dow'][$i]."\t".$_POST['observance'][$i]."\n");
                                }
                                fclose($fp);
***************
*** 229,234 ****
                        if($this->so->holiday_total($locale) == 0)
                        {
-                               global $HTTP_HOST, $SERVER_PORT;
-               
                                @set_time_limit(0);
  
--- 224,227 ----
***************
*** 242,249 ****
                                else
                                {
!                                       $pos = strpos(' 
'.$GLOBALS['phpgw_info']['server']['webserver_url'],$HTTP_HOST);
                                        if($pos == 0)
                                        {
!                                               switch($SERVER_PORT)
                                                {
                                                        case 80:
--- 235,242 ----
                                else
                                {
!                                       $pos = strpos(' 
'.$GLOBALS['phpgw_info']['server']['webserver_url'],$GLOBALS['HTTP_HOST']);
                                        if($pos == 0)
                                        {
!                                               switch($GLOBALS['SERVER_PORT'])
                                                {
                                                        case 80:
***************
*** 254,258 ****
                                                                break;
                                                }
!                                               $server_host = 
$http_protocol.$HTTP_HOST.$GLOBALS['phpgw_info']['server']['webserver_url'];
                                        }
                                        else
--- 247,251 ----
                                                                break;
                                                }
!                                               $server_host = 
$http_protocol.$GLOBALS['HTTP_HOST'].$GLOBALS['phpgw_info']['server']['webserver_url'];
                                        }
                                        else
***************
*** 298,302 ****
                        if(@$GLOBALS['HTTP_POST_VARS']['submit'])
                        {
!                               $holiday = 
$GLOBALS['HTTP_POST_VARS']['holiday'];
  
                                if(empty($holiday['mday']))
--- 291,295 ----
                        if(@$GLOBALS['HTTP_POST_VARS']['submit'])
                        {
!                               $holiday = get_var('holiday',Array('POST'));
  
                                if(empty($holiday['mday']))





reply via email to

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