phpgroupware-cvs
[Top][All Lists]
Advanced

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

[Phpgroupware-cvs] CVS: email/inc class.bocompose.inc.php,NONE,1.1 class


From: Angelo Tony Puglisi <address@hidden>
Subject: [Phpgroupware-cvs] CVS: email/inc class.bocompose.inc.php,NONE,1.1 class.uicompose.inc.php,NONE,1.1 class.boindex.inc.php,1.16,1.17 class.bomessage.inc.php,1.3,1.4 class.bosend.inc.php,1.4,1.5 class.mail_msg_base.inc.php,1.53,1.54 class.mail_msg_display.inc.php,1.26,1.27 class.mail_msg_wrappers.inc.php,1.18,1.19
Date: Tue, 08 Jan 2002 10:06:06 -0500

Update of /cvsroot/phpgroupware//email/inc
In directory subversions:/tmp/cvs-serv13881/email/inc

Modified Files:
        class.boindex.inc.php class.bomessage.inc.php 
        class.bosend.inc.php class.mail_msg_base.inc.php 
        class.mail_msg_display.inc.php class.mail_msg_wrappers.inc.php 
Added Files:
        class.bocompose.inc.php class.uicompose.inc.php 
Log Message:
alternate php3 compat, ntier compose, other bug fixes

***** Error reading new file: [Errno 2] No such file or directory: 
'class.bocompose.inc.php'
***** Error reading new file: [Errno 2] No such file or directory: 
'class.uicompose.inc.php'
Index: class.boindex.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware//email/inc/class.boindex.inc.php,v
retrieving revision 1.16
retrieving revision 1.17
diff -C2 -r1.16 -r1.17
*** class.boindex.inc.php       7 Jan 2002 10:50:42 -0000       1.16
--- class.boindex.inc.php       8 Jan 2002 15:06:03 -0000       1.17
***************
*** 342,348 ****
                        $this->xi['ctrl_bar_back2'] = 
$GLOBALS['phpgw_info']['theme']['row_off'];
                        $this->xi['compose_link'] = $GLOBALS['phpgw']->link(
!                                                               
'/'.$GLOBALS['phpgw_info']['flags']['currentapp'].'/compose.php',
                                                                // this data 
tells us where to return to after sending a message
!                                                               
'fldball[folder]='.$GLOBALS['phpgw']->msg->prep_folder_out()
                                                                
.'&fldball[acctnum]='.$GLOBALS['phpgw']->msg->get_acctnum()
                                                                
.'&sort='.$GLOBALS['phpgw']->msg->get_arg_value('sort')
--- 342,349 ----
                        $this->xi['ctrl_bar_back2'] = 
$GLOBALS['phpgw_info']['theme']['row_off'];
                        $this->xi['compose_link'] = $GLOBALS['phpgw']->link(
!                                                               '/index.php',
!                                                                
'menuaction=email.uicompose.compose'
                                                                // this data 
tells us where to return to after sending a message
!                                                               
.'&fldball[folder]='.$GLOBALS['phpgw']->msg->prep_folder_out()
                                                                
.'&fldball[acctnum]='.$GLOBALS['phpgw']->msg->get_acctnum()
                                                                
.'&sort='.$GLOBALS['phpgw']->msg->get_arg_value('sort')
***************
*** 699,707 ****
                        
                        $this->xi['ctrl_bar_back2'] = 
$GLOBALS['phpgw_info']['theme']['row_off'];
!                       $this->xi['compose_link'] = 
$GLOBALS['phpgw']->link('/'.$GLOBALS['phpgw_info']['flags']['currentapp'].'/compose.php','folder='.$GLOBALS['phpgw']->msg->prep_folder_out(''));
                        if ($this->xi['mailsvr_supports_folders'])
                        {
                                //$this->xi['folders_link'] = 
$GLOBALS['phpgw']->link('/'.$GLOBALS['phpgw_info']['flags']['currentapp'].'/folder.php');
!                               $this->xi['folders_link'] = 
$GLOBALS['phpgw']->link('/index.php',$GLOBALS['phpgw']->msg->get_arg_value('folder_menuaction'));
                                $this->xi['folders_href'] = '<a 
href="'.$this->xi['folders_link'].'">'.$this->xi['folders_txt2'].'</a>';
                
--- 700,715 ----
                        
                        $this->xi['ctrl_bar_back2'] = 
$GLOBALS['phpgw_info']['theme']['row_off'];
!                       $this->xi['compose_link'] = $GLOBALS['phpgw']->link(
!                                                               '/index.php',
!                                                                
'menuaction=email.uicompose.compose'
!                                                               
.'&fldball[folder]='.$GLOBALS['phpgw']->msg->prep_folder_out()
!                                                               
.'&fldball[acctnum]='.$GLOBALS['phpgw']->msg->get_acctnum());
!                       
                        if ($this->xi['mailsvr_supports_folders'])
                        {
                                //$this->xi['folders_link'] = 
$GLOBALS['phpgw']->link('/'.$GLOBALS['phpgw_info']['flags']['currentapp'].'/folder.php');
!                               $this->xi['folders_link'] = 
$GLOBALS['phpgw']->link(
!                                                       '/index.php',
!                                                       
$GLOBALS['phpgw']->msg->get_arg_value('folder_menuaction'));
                                $this->xi['folders_href'] = '<a 
href="'.$this->xi['folders_link'].'">'.$this->xi['folders_txt2'].'</a>';
                
***************
*** 714,719 ****
                                $this->xi['folders_btn'] = '&nbsp;';
                        }
!                       $this->xi['email_prefs_link'] = 
$GLOBALS['phpgw']->link('/index.php','menuaction=email.uipreferences.preferences');
!                       $this->xi['filters_link'] = 
$GLOBALS['phpgw']->link('/'.$GLOBALS['phpgw_info']['flags']['currentapp'].'/filters.php');
                        $this->xi['filters_href'] = '<a 
href="'.$this->xi['filters_link'].'">'.$this->xi['filters_txt'].'</a>';
                        // multiple account maintenance - not yet implemented
--- 722,730 ----
                                $this->xi['folders_btn'] = '&nbsp;';
                        }
!                       $this->xi['email_prefs_link'] = $GLOBALS['phpgw']->link(
!                                                               '/index.php',
!                                                               
'menuaction=email.uipreferences.preferences');
!                       $this->xi['filters_link'] = $GLOBALS['phpgw']->link(
!                                                               
'/'.$GLOBALS['phpgw_info']['flags']['currentapp'].'/filters.php');
                        $this->xi['filters_href'] = '<a 
href="'.$this->xi['filters_link'].'">'.$this->xi['filters_txt'].'</a>';
                        // multiple account maintenance - not yet implemented

Index: class.bomessage.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware//email/inc/class.bomessage.inc.php,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -r1.3 -r1.4
*** class.bomessage.inc.php     4 Jan 2002 06:21:16 -0000       1.3
--- class.bomessage.inc.php     8 Jan 2002 15:06:03 -0000       1.4
***************
*** 255,260 ****
                                $from_and_compose_link = 
                                        
$GLOBALS['phpgw']->msg->href_maketag($GLOBALS['phpgw']->link(
!                                                
'/'.$GLOBALS['phpgw_info']['flags']['currentapp'].'/compose.php',
!                                               $msgball['uri']
                                                .'&to='.urlencode($from_plain)
                                                
.'&personal='.urlencode($from_personal)
--- 255,261 ----
                                $from_and_compose_link = 
                                        
$GLOBALS['phpgw']->msg->href_maketag($GLOBALS['phpgw']->link(
!                                               '/index.php',
!                                                
'menuaction=email.uicompose.compose'
!                                               .'&'.$msgball['uri']
                                                .'&to='.urlencode($from_plain)
                                                
.'&personal='.urlencode($from_personal)
***************
*** 313,318 ****
                                        $to_real_name = 
$GLOBALS['phpgw']->msg->href_maketag(
                                                $GLOBALS['phpgw']->link(
!                                                        
'/'.$GLOBALS['phpgw_info']['flags']['currentapp'].'/compose.php',
!                                                       $msgball['uri']
                                                        
.'&to='.urlencode($to_plain)
                                                        
.'&personal='.urlencode($to_personal)
--- 314,320 ----
                                        $to_real_name = 
$GLOBALS['phpgw']->msg->href_maketag(
                                                $GLOBALS['phpgw']->link(
!                                                       '/index.php',
!                                                        
'menuaction=email.uicompose.compose'
!                                                       .'&'.$msgball['uri']
                                                        
.'&to='.urlencode($to_plain)
                                                        
.'&personal='.urlencode($to_personal)
***************
*** 370,375 ****
                                        }
                                        $cc_real_name = 
$GLOBALS['phpgw']->msg->href_maketag($GLOBALS['phpgw']->link(
!                                                        
'/'.$GLOBALS['phpgw_info']['flags']['currentapp'].'/compose.php',
!                                                       $msgball['uri']
                                                        
.'&to='.urlencode($cc_plain)
                                                        
.'&personal='.urlencode($cc_personal)
--- 372,378 ----
                                        }
                                        $cc_real_name = 
$GLOBALS['phpgw']->msg->href_maketag($GLOBALS['phpgw']->link(
!                                                       '/index.php',
!                                                        
'menuaction=email.uicompose.compose'
!                                                       .'&'.$msgball['uri']
                                                        
.'&to='.urlencode($cc_plain)
                                                        
.'&personal='.urlencode($cc_personal)
***************
*** 475,480 ****
                        $reply_img = 
$GLOBALS['phpgw']->msg->img_maketag($image_dir.'/sm_reply.gif',lang('reply'),'','','0');
                        $reply_url = $GLOBALS['phpgw']->link(
!                                        
'/'.$GLOBALS['phpgw_info']['flags']['currentapp'].'/compose.php',
!                                        'action=reply'
                                        .'&'.$msgball['uri']
                                        .$first_presentable
--- 478,484 ----
                        $reply_img = 
$GLOBALS['phpgw']->msg->img_maketag($image_dir.'/sm_reply.gif',lang('reply'),'','','0');
                        $reply_url = $GLOBALS['phpgw']->link(
!                                       '/index.php',
!                                        'menuaction=email.uicompose.compose'
!                                       .'&action=reply'
                                        .'&'.$msgball['uri']
                                        .$first_presentable
***************
*** 487,492 ****
                        $replyall_img = 
$GLOBALS['phpgw']->msg->img_maketag($image_dir .'/sm_reply_all.gif',lang('reply 
all'),'','','0');
                        $replyall_url = $GLOBALS['phpgw']->link(
!                                        
'/'.$GLOBALS['phpgw_info']['flags']['currentapp'].'/compose.php',
!                                        'action=replyall'
                                        .'&'.$msgball['uri']
                                        .$first_presentable
--- 491,497 ----
                        $replyall_img = 
$GLOBALS['phpgw']->msg->img_maketag($image_dir .'/sm_reply_all.gif',lang('reply 
all'),'','','0');
                        $replyall_url = $GLOBALS['phpgw']->link(
!                                       '/index.php',
!                                        'menuaction=email.uicompose.compose'
!                                       .'&action=replyall'
                                        .'&'.$msgball['uri']
                                        .$first_presentable
***************
*** 499,504 ****
                        $forward_img = 
$GLOBALS['phpgw']->msg->img_maketag($image_dir 
.'/sm_forward.gif',lang('forward'),'','','0');
                        $forward_url =  $GLOBALS['phpgw']->link(
!                                        
'/'.$GLOBALS['phpgw_info']['flags']['currentapp'].'/compose.php',
!                                        'action=forward'
                                        .'&'.$msgball['uri']
                                        .'&fwd_proc='.$fwd_proc
--- 504,510 ----
                        $forward_img = 
$GLOBALS['phpgw']->msg->img_maketag($image_dir 
.'/sm_forward.gif',lang('forward'),'','','0');
                        $forward_url =  $GLOBALS['phpgw']->link(
!                                       '/index.php',
!                                        'menuaction=email.uicompose.compose'
!                                       .'&action=forward'
                                        .'&'.$msgball['uri']
                                        .'&fwd_proc='.$fwd_proc

Index: class.bosend.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware//email/inc/class.bosend.inc.php,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -r1.4 -r1.5
*** class.bosend.inc.php        4 Jan 2002 06:21:16 -0000       1.4
--- class.bosend.inc.php        8 Jan 2002 15:06:03 -0000       1.5
***************
*** 104,129 ****
                                
$GLOBALS['phpgw']->msg->login_error($GLOBALS['PHP_SELF'].', send()');
                        }
! 
! 
! 
! 
                        $not_set = $GLOBALS['phpgw']->msg->not_set;
                        $msgball = 
$GLOBALS['phpgw']->msg->get_pref_value('msgball');
-                       /*
-                       // -- debug ----
-                       $to = $GLOBALS['phpgw']->msg->stripslashes_gpc($to);
-                       $this->mail_out['to'] = 
$GLOBALS['phpgw']->msg->make_rfc_addy_array($to);
-                       $cc = $GLOBALS['phpgw']->msg->stripslashes_gpc($cc);
-                       $this->mail_out['cc'] = 
$GLOBALS['phpgw']->msg->make_rfc_addy_array($cc);
-                       
-                       //echo '<br> var dump $this->mail_out[to] <br>';
-                       //var_dump($this->mail_out['to']);
-                       
-                       //send_message_cleanup($mailbox);
-                       send_message_cleanup($this->mail_out);
-                       $GLOBALS['phpgw']->common->phpgw_footer();
-                       exit;
-                       // end ----  debug ------
-                       */
                        
                        //  -------  Init Array Structure For Outgoing Mail  
-----------
--- 104,112 ----
                                
$GLOBALS['phpgw']->msg->login_error($GLOBALS['PHP_SELF'].', send()');
                        }
!                       
!                       // ---- BEGIN BO SEND LOGIC
!                       
                        $not_set = $GLOBALS['phpgw']->msg->not_set;
                        $msgball = 
$GLOBALS['phpgw']->msg->get_pref_value('msgball');
                        
                        //  -------  Init Array Structure For Outgoing Mail  
-----------
***************
*** 145,153 ****
                        $this->mail_out['is_forward'] = False;
                        $this->mail_out['fwd_proc'] = '';
!                       // this array gets filled with functiuon 
"make_rfc_addy_array", but it will have only 1 numbered array, 
$this->mail_out['from'][0]
!                       // note that sending it through make_rfc_addy_array 
will ensure correct formatting of non us-ascii chars (if any) in the use's 
fullname
!                       $this->mail_out['from'] = Array();
!                       $this->mail_out['from'] = 
$GLOBALS['phpgw']->msg->make_rfc_addy_array('"'.$GLOBALS['phpgw_info']['user']['fullname'].'"
 <'.$GLOBALS['phpgw']->msg->get_pref_value('address').'>');
!                       // this array gets filled with functiuon 
"make_rfc_addy_array", but it will have only 1 numbered array, 
$this->mail_out['sender'][0]
                        $this->mail_out['sender'] = '';
                        $this->mail_out['charset'] = '';
--- 128,132 ----
                        $this->mail_out['is_forward'] = False;
                        $this->mail_out['fwd_proc'] = '';
!                       $this->mail_out['from'] = array();
                        $this->mail_out['sender'] = '';
                        $this->mail_out['charset'] = '';
***************
*** 155,160 ****
                        
                        //  -------  Start Filling Array Structure For Outgoing 
Mail  -----------
!                       // -----  x-phpgw custom message type RPC-like flag  
------
!                       // RARELY USED, maybe NEVER used, most implementation 
code for this is commented out
                        if (($GLOBALS['phpgw']->msg->get_isset_arg('msgtype'))
                        && ($GLOBALS['phpgw']->msg->get_arg_value('msgtype') != 
''))
--- 134,154 ----
                        
                        //  -------  Start Filling Array Structure For Outgoing 
Mail  -----------
!                       
!                       // -----  X-PHPGW flag (msgtype)  ------
!                       /*!
!                       @var msgtype
!                       @abstract obsoleted way phpgw apps used to inter-operate
!                       @discussion NOTE: this is a vestigal way for phpgw apps 
to inter-operate, 
!                       I *think* this is being obsoleted via n-tiering and 
xml-rpc / soap methods.
!                       RARELY USED, maybe NEVER used, most email code for this 
is now commented out
!                       "back in the day..." the "x-phpgw" header was specified 
by a phpgw app *other* than the email app
!                       which was used to include special phpgw related 
handling instructions in the message which 
!                       to the message intentended to be noticed and processed 
by the phpgw email app when the 
!                       user open the mail for viewing, at which time the phpgw 
email app would issue the 
!                       special handling instructions contained in the 
"x-phpgw" header.
!                       even before n-tiering of the phpgw apps and api begain, 
I (angles) considered this a possible
!                       area of abuse and I commented out the code in the email 
app that would notice, process and issue
!                       those instructions.
!                       */
                        if (($GLOBALS['phpgw']->msg->get_isset_arg('msgtype'))
                        && ($GLOBALS['phpgw']->msg->get_arg_value('msgtype') != 
''))
***************
*** 164,168 ****
--- 158,172 ----
                                // after this, ONLY USE $this->mail_out 
structure for this
                        }
+                       
                        // -----  CHARSET  -----
+                       /*!
+                       @property charset
+                       @abstract not user specified, not a user var, not an 
argument, not a paramater.
+                       @discussion charset could take up a lot of notes here, 
suffice to say that email began life as a
+                       US-ASCII thing and still us-ascii chars are strictly 
required for some headers, while other headers
+                       and the body have various alternative ways to deal with 
other charsets, ways that are well documented
+                       in email and other RFC's and other literature. In the 
rare event that the phpgw api is unable 
+                       to provide us with a charset value, we use the RFC 
specified default value of "US-ASCII"
+                       */
                        if (lang('charset') != '')
                        {
***************
*** 174,186 ****
                                $this->mail_out['charset'] = 'US-ASCII';
                        }
                        // -----  SENDER  -----
!                       // rfc2822 - sender is only used if some one NOT the 
author (ex. the author's secretary) is sending the authors email
                        if (($GLOBALS['phpgw']->msg->get_isset_arg('sender'))
                        && ($GLOBALS['phpgw']->msg->get_arg_value('sender') != 
''))
                        {
                                // clean data of magic_quotes escaping (if any)
!                               $GLOBALS['phpgw']->msg->set_arg_value('sender', 
$GLOBALS['phpgw']->msg->stripslashes_gpc($GLOBALS['phpgw']->msg->get_arg_value('sender')));
                                // convert general address string into 
structured data array of addresses, each has properties [plain] and [personal]
!                               $sender_array = 
$GLOBALS['phpgw']->msg->make_rfc_addy_array($GLOBALS['phpgw']->msg->get_arg_value('sender'));
                                // realistically sender array should have no 
more than one member (can there really be more than 1 sender?)
                                if (count($sender_array) > 0)
--- 178,238 ----
                                $this->mail_out['charset'] = 'US-ASCII';
                        }
+                       
+                       // -----  FROM  -----
+                       /*!
+                       @var from
+                       @abstract the mail's author, OPTIONAL, usually no need 
to specify this as an arg passed to the script.
+                       @discussion Generally this var does not need to be 
specified. When the mail is being sent from the 
+                       user's default email account (or mail on behalf of the 
user, like automated email notifications),
+                       we generate the "from" header for the user, hence no 
custom "from" arg is necessary.
+                       This is the most common scenario, in which case we 
generate the "from" value as follows:
+                       (1) the user's "fullname" (a.k.a. the "personal" part 
of the address) is always picked up 
+                       from the phpgw api's value that contains the users 
name, and 
+                       (2) the user's email address is either (2a) the default 
value from the phpgw api which was 
+                       passed into the user's preferences because the user 
specified no custom email address preference, or
+                       (2b) the user specified a custom email address in the 
email preferences in which case the aformentioned
+                       phpgw api default email address is not used in the 
user's preferences array, this user supplied
+                       value is used instead.
+                       Providing a "from" arg is usually for extra email 
accounts and/or alternative email profiles, 
+                       where the user wants other than the "from" info 
otherwise defaultly associated with this email acccount.
+                       NOTE: from != sender
+                       from is who the mail came from assuming that person is 
also the mail's author.
+                       this is by far the most common scenario, "from" and 
"author" are usually one in the same
+                       (see below for info on when to *also* use "sender" - 
VERY rare)
+                       */
+                       if (($GLOBALS['phpgw']->msg->get_isset_arg('from'))
+                       && ($GLOBALS['phpgw']->msg->get_arg_value('from') != 
''))
+                       {
+                               $from_assembled = 
$GLOBALS['phpgw']->msg->get_arg_value('sender');
+                       }
+                       else
+                       {
+                               $from_name = 
$GLOBALS['phpgw_info']['user']['fullname'];
+                               $from_address = 
$GLOBALS['phpgw']->msg->get_pref_value('address');
+                               $from_assembled = '"'.$from_name.'" 
<'.$from_address.'>';
+                       }
+                       // this array gets filled with functiuon 
"make_rfc_addy_array", but it will have only 1 numbered array, 
$this->mail_out['from'][0]
+                       // note that sending it through make_rfc_addy_array 
will ensure correct formatting of non us-ascii chars (if any) in the use's 
fullname
+                       $this->mail_out['from'] = 
$GLOBALS['phpgw']->msg->make_rfc_addy_array($from_assembled);
+                       
                        // -----  SENDER  -----
!                       /*!
!                       @var sender
!                       @abstract OPTIONAL only used in the rare event that the 
person sending the email 
!                       is NOT that email's author.
!                       @discussion RFC2822 makes clear that the Sender header 
is ONLY used if some one 
!                       NOT the author (ex. the author's secretary) is sending 
the author's email.
!                       RFC2822 considers that "From" = the author and the 
"Sender" = the person who clicked the
!                       send button. Generally they are one in the same and 
generally the Sender header (and hence this 
!                       "sender" var) is NOT needed, not used, not included in 
the email's headers.
!                       */
                        if (($GLOBALS['phpgw']->msg->get_isset_arg('sender'))
                        && ($GLOBALS['phpgw']->msg->get_arg_value('sender') != 
''))
                        {
                                // clean data of magic_quotes escaping (if any)
!                               $this->mail_out['sender'] = 
$GLOBALS['phpgw']->msg->stripslashes_gpc($GLOBALS['phpgw']->msg->get_arg_value('sender'));
                                // convert general address string into 
structured data array of addresses, each has properties [plain] and [personal]
!                               // this array gets filled with functiuon 
"make_rfc_addy_array", but it will have only 1 numbered array, 
$this->mail_out['sender'][0]
!                               $sender_array = 
$GLOBALS['phpgw']->msg->make_rfc_addy_array($this->mail_out['sender']);
                                // realistically sender array should have no 
more than one member (can there really be more than 1 sender?)
                                if (count($sender_array) > 0)
***************
*** 193,206 ****
                                        }
                                }
!                               // after this, ONLY USE $this->mail_out 
structure for this
!                               // it will wither be blank string OR a string 
which should be 1 email address
                        }
                        // -----  DATE  -----
!                       // RFC2822: date *should* be local time with the 
correct offset, but this is problematic on many Linux boxen
!                       // FUTURE: figure out a host independant way of getting 
the correct rfc time and TZ offset
                        $this->mail_out['date'] = gmdate('D, d M Y H:i:s').' 
+0000';
                        // -----  MYMACHINE - The MTA HELO/ELHO DOMAIN ARG  
-----
!                       // rfc2821 sect 4.1.1.1 - almost always the Fully 
Qualified Domain Name of the SMTP client maching
!                       // rarely, when the maching has dynamic FQD or no 
reverse mapping is available, *should* be "address leteral" (see sect 4.1.3)
                        $this->mail_out['mta_elho_mymachine'] = 
trim($GLOBALS['phpgw_info']['server']['hostname']);
                        
--- 245,280 ----
                                        }
                                }
!                               else
!                               {
!                                       $this->mail_out['sender'] = '';
!                               }
!                               // after this, ONLY USE $this->mail_out[] 
structure for this
!                               // it will either be blank string OR a string 
which should be 1 email address
                        }
                        // -----  DATE  -----
!                       /*!
!                       @property date
!                       @abstract not user specified, not a user var, not an 
argument, not a paramater.
!                       @discussion According to RFC2822 the Date header 
*should* be the local time with the correct 
!                       timezone offset relative to GMT, however this is 
problematic on many Linux boxen, and
!                       in general I have found that reliably extracting this 
data from the host OS can be tricky, 
!                       so instead we use a fallback value which is simply GMT 
time, which is allowed under RFC2822 
!                       but not preferred.
!                       FUTURE: figure out a host independant way of getting 
the correct rfc time and TZ offset
!                       */
                        $this->mail_out['date'] = gmdate('D, d M Y H:i:s').' 
+0000';
+                       
                        // -----  MYMACHINE - The MTA HELO/ELHO DOMAIN ARG  
-----
!                       /*!
!                       @property elho SMTP handshake domain value
!                       @abstract not user specified, not a user var, not an 
argument, not a paramater.
!                       @discussion when class.msg_send conducts the handshake 
with the SMTP server, this 
!                       will be the required domain value that we supply to the 
SMTP server. Phpgw is considered 
!                       the client to the SMTP server. 
!                       RFC2821 sect 4.1.1.1 specifies this value is almost 
always the Fully Qualified Domain Name 
!                       of the SMTP client machine, but rarely, when said 
client machine has dynamic FQDN or no reverse 
!                       mapping is available, this value *should* be "address 
leteral" (see sect 4.1.3).
!                       Refer to the documentation for BIND for further reading 
on reverse lookup issues.
!                       */
                        $this->mail_out['mta_elho_mymachine'] = 
trim($GLOBALS['phpgw_info']['server']['hostname']);
                        

Index: class.mail_msg_base.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware//email/inc/class.mail_msg_base.inc.php,v
retrieving revision 1.53
retrieving revision 1.54
diff -C2 -r1.53 -r1.54
*** class.mail_msg_base.inc.php 7 Jan 2002 10:50:42 -0000       1.53
--- class.mail_msg_base.inc.php 8 Jan 2002 15:06:03 -0000       1.54
***************
*** 27,30 ****
--- 27,34 ----
  
        /* $Id$ */
+       class mail_dcom_holder
+       {
+               var $dcom = '';
+       }
  
    class mail_msg_base
***************
*** 147,151 ****
        function mail_msg()
        {
!               if ($this->debug_logins > 0) { echo 'mail_msg: *constructor*: 
$GLOBALS[PHP_SELF] = ['.$GLOBALS['PHP_SELF'].'] $this->acctnum = 
['.$this->acctnum.']  get_class($this) : "'.get_class($this).'" ; 
get_parent_class($this) : "'.get_parent_class($this).'"<br>'; }
                if ($this->debug_logins > 1) { echo 'mail_msg: *constructor*: 
$this->acctnum = ['.$this->acctnum.'] ; $this->a  Dump<pre>'; 
print_r($this->a); echo '</pre>'; }
                
--- 151,155 ----
        function mail_msg()
        {
!               //if ($this->debug_logins > 0) { echo 'mail_msg: *constructor*: 
$GLOBALS[PHP_SELF] = ['.$GLOBALS['PHP_SELF'].'] $this->acctnum = 
['.$this->acctnum.']  get_class($this) : "'.get_class($this).'" ; 
get_parent_class($this) : "'.get_parent_class($this).'"<br>'; }
                if ($this->debug_logins > 1) { echo 'mail_msg: *constructor*: 
$this->acctnum = ['.$this->acctnum.'] ; $this->a  Dump<pre>'; 
print_r($this->a); echo '</pre>'; }
                
***************
*** 675,680 ****
                
                //if ($this->debug_logins > 2) { echo 'mail_msg: begin_request: 
POST create_email_preferences GLOBALS[phpgw_info][user][preferences][email] 
dump:<pre>'; print_r($GLOBALS['phpgw_info']['user']['preferences']['email']) ; 
echo '</pre>';}
!               if ($this->debug_logins > 2) { echo 'mail_msg: begin_request: 
POST create_email_preferences $this->get_all_prefs() dump:<pre>'; 
print_r($this->get_all_prefs()) ; echo '</pre>';}
!               //if ($this->debug_logins > 2) { echo 'mail_msg: begin_request: 
POST create_email_preferences direct access dump of $this->a  :<pre>'; 
print_r($this->a) ; echo '</pre>';}
                //if ($this->debug_logins > 2) { echo 'mail_msg: begin_request: 
preferences->create_email_preferences called, 
GLOBALS[phpgw_info][user][preferences] dump:<pre>'; 
print_r($GLOBALS['phpgw_info']['user']['preferences']) ; echo '</pre>';}
                //if ($this->debug_logins > 2) { echo 'mail_msg: begin_request: 
preferences->create_email_preferences called, GLOBALS[phpgw_info][user] 
dump:<pre>'; print_r($GLOBALS['phpgw_info']['user']) ; echo '</pre>';}
--- 679,684 ----
                
                //if ($this->debug_logins > 2) { echo 'mail_msg: begin_request: 
POST create_email_preferences GLOBALS[phpgw_info][user][preferences][email] 
dump:<pre>'; print_r($GLOBALS['phpgw_info']['user']['preferences']['email']) ; 
echo '</pre>';}
!               //if ($this->debug_logins > 2) { echo 'mail_msg: begin_request: 
POST create_email_preferences $this->get_all_prefs() dump:<pre>'; 
print_r($this->get_all_prefs()) ; echo '</pre>';}
!               if ($this->debug_logins > 2) { echo 'mail_msg: begin_request: 
POST create_email_preferences direct access dump of $this->a  :<pre>'; 
print_r($this->a) ; echo '</pre>';}
                //if ($this->debug_logins > 2) { echo 'mail_msg: begin_request: 
preferences->create_email_preferences called, 
GLOBALS[phpgw_info][user][preferences] dump:<pre>'; 
print_r($GLOBALS['phpgw_info']['user']['preferences']) ; echo '</pre>';}
                //if ($this->debug_logins > 2) { echo 'mail_msg: begin_request: 
preferences->create_email_preferences called, GLOBALS[phpgw_info][user] 
dump:<pre>'; print_r($GLOBALS['phpgw_info']['user']) ; echo '</pre>';}
***************
*** 795,806 ****
                        
                        // ----  php3 compatibility  ----
                        // apparently php3 wants you to create the object 
first, then put it in the array
                        $this_server_type = 
$this->get_pref_value('mail_server_type');
!                       $this_dcom = CreateObject("email.mail_dcom", 
$this_server_type);
                        // ok, now put that object into the array
!                       $this->a[$this->acctnum]['dcom'] = $this_dcom;
!                       $tmp_a = $this->a[$this->acctnum];
                        // initialize the dcom class variables
!                       $tmp_a['dcom']->mail_dcom_base();
                        
                        // ----  there are 2 settings from this mail_msg object 
we need to pass down to the child dcom object:  ----
--- 799,827 ----
                        
                        // ----  php3 compatibility  ----
+                       // make a "new" holder object to hold the dcom object
+                       // remember, by now we have determined an acctnum
+                       if ($this->debug_logins > 1) { echo 'mail_msg: 
begin_request: creating new dcom_holder at 
$this->a['.$this->acctnum.'][dcom_holder]'.'<br>'; }
+                       //$this->a[$this->acctnum]['dcom_holder'] = new 
mail_dcom_holder;
+                       //$this_dcom_holder = new mail_dcom_holder;
+                       //$this->a[$this->acctnum]['dcom_holder'] = 
$this_dcom_holder;
+                       //$this->a[$this->acctnum]['dcom_holder']->dcom = '';
+                       
                        // apparently php3 wants you to create the object 
first, then put it in the array
                        $this_server_type = 
$this->get_pref_value('mail_server_type');
!                       //$this_dcom_holder->dcom = 
CreateObject("email.mail_dcom", $this_server_type);
!                       //$this_dcom = CreateObject("email.mail_dcom", 
$this_server_type);
                        // ok, now put that object into the array
!                       //$this->a[$this->acctnum]['dcom'] = $this_dcom;
!                       //$this->a[$this->acctnum]['dcom_holder']->dcom = 
$this_dcom;
!                       $this_acctnum = (string)$this->acctnum;
!                       //$this->a[$this_acctnum]['dcom_holder'] = 
$this_dcom_holder;
!                       $GLOBALS['phpgw_dcom_'.$this_acctnum] = new 
mail_dcom_holder;
!                       $GLOBALS['phpgw_dcom_'.$this_acctnum]->dcom = 
CreateObject("email.mail_dcom", $this_server_type);
!                       //$this->a[$this->acctnum]['dcom_holder']->dcom = 
CreateObject("email.mail_dcom", $this_server_type);
!                       //$tmp_a = $this->a[$this->acctnum];
                        // initialize the dcom class variables
!                       //$tmp_a['dcom']->mail_dcom_base();
!                       
//$this->a[$this->acctnum]['dcom_holder']->dcom->mail_dcom_base();
!                       
$GLOBALS['phpgw_dcom_'.$this_acctnum]->dcom->mail_dcom_base();
                        
                        // ----  there are 2 settings from this mail_msg object 
we need to pass down to the child dcom object:  ----
***************
*** 809,818 ****
                        && ($this->get_pref_value('enable_utf7')))
                        {
!                               $tmp_a['dcom']->enable_utf7 = True;
                        }
                        // (2)  Do We Force use of msg UID's
                        if ($this->force_msg_uids == True)
                        {
!                               $tmp_a['dcom']->force_msg_uids = True;
                        }
                        
--- 830,841 ----
                        && ($this->get_pref_value('enable_utf7')))
                        {
!                               //$tmp_a['dcom']->enable_utf7 = True;
!                               
$GLOBALS['phpgw_dcom_'.$this_acctnum]->dcom->enable_utf7 = True;
                        }
                        // (2)  Do We Force use of msg UID's
                        if ($this->force_msg_uids == True)
                        {
!                               //$tmp_a['dcom']->force_msg_uids = True;
!                               
$GLOBALS['phpgw_dcom_'.$this_acctnum]->dcom->force_msg_uids = True;
                        }
                        
***************
*** 820,825 ****
                        // login to INBOX because we know that always(?) should 
exist on an imap server and pop server
                        // after we are logged in we can get additional info 
that will lead us to the desired folder (if not INBOX)
!                       if ($this->debug_logins > 1) { echo 'mail_msg: 
begin_request: about to call dcom->open: 
this->a['.$this->acctnum.'][dcom]->open('.$mailsvr_callstr."INBOX".', 
'.$user.', '.$pass.', )'.'<br>'; }
!                       $mailsvr_stream = 
$tmp_a['dcom']->open($mailsvr_callstr."INBOX", $user, $pass, '');
                        $pass = '';
                        set_time_limit(0);
--- 843,849 ----
                        // login to INBOX because we know that always(?) should 
exist on an imap server and pop server
                        // after we are logged in we can get additional info 
that will lead us to the desired folder (if not INBOX)
!                       if ($this->debug_logins > 1) { echo 'mail_msg: 
begin_request: about to call dcom->open: 
this->a['.$this->acctnum.'][dcom_holder]->dcom->open('.$mailsvr_callstr."INBOX".',
 '.$user.', '.$pass.', )'.'<br>'; }
!                       //$mailsvr_stream = 
$tmp_a['dcom']->open($mailsvr_callstr."INBOX", $user, $pass, '');
!                       $mailsvr_stream = 
$GLOBALS['phpgw_dcom_'.$this_acctnum]->dcom->open($mailsvr_callstr."INBOX", 
$user, $pass, '');
                        $pass = '';
                        set_time_limit(0);
***************
*** 924,928 ****
                                if ($this->debug_logins > 1) { echo 'mail_msg: 
begin_request: need to switch folders (reopen) from INBOX to 
$processed_folder_arg: '.$processed_folder_arg.'<br>';}
                                if ($this->debug_logins > 1) { echo 'mail_msg: 
begin_request: about to issue: 
$this->a['.$this->acctnum.'][dcom]->reopen('.$mailsvr_stream.', 
'.$mailsvr_callstr.$processed_folder_arg,', )'.'<br>';}
!                               $did_reopen = 
$tmp_a['dcom']->reopen($mailsvr_stream, $mailsvr_callstr.$processed_folder_arg, 
'');
                                if ($this->debug_logins > 1) { echo 'mail_msg: 
begin_request: reopen returns: '.serialize($did_reopen).'<br>';}
                                // error check
--- 948,953 ----
                                if ($this->debug_logins > 1) { echo 'mail_msg: 
begin_request: need to switch folders (reopen) from INBOX to 
$processed_folder_arg: '.$processed_folder_arg.'<br>';}
                                if ($this->debug_logins > 1) { echo 'mail_msg: 
begin_request: about to issue: 
$this->a['.$this->acctnum.'][dcom]->reopen('.$mailsvr_stream.', 
'.$mailsvr_callstr.$processed_folder_arg,', )'.'<br>';}
!                               //$did_reopen = 
$tmp_a['dcom']->reopen($mailsvr_stream, $mailsvr_callstr.$processed_folder_arg, 
'');
!                               $did_reopen = 
$GLOBALS['phpgw_dcom_'.$this_acctnum]->dcom->reopen($mailsvr_stream, 
$mailsvr_callstr.$processed_folder_arg, '');
                                if ($this->debug_logins > 1) { echo 'mail_msg: 
begin_request: reopen returns: '.serialize($did_reopen).'<br>';}
                                // error check
***************
*** 951,956 ****
                        // we can NOT put "start" in auto refresh or user may 
not see the 1st index page on refresh
                        $this->index_refresh_uri = 
!                               $this->index_menuaction
!                               .'&folder='.$this->prep_folder_out('')
                                .'&sort='.$this->get_arg_value('sort')
                                .'&order='.$this->get_arg_value('order');
--- 976,982 ----
                        // we can NOT put "start" in auto refresh or user may 
not see the 1st index page on refresh
                        $this->index_refresh_uri = 
!                               'menuaction=email.uiindex.index'
!                               .'&fldball[folder]='.$this->prep_folder_out()
!                               .'&fldball[acctnum]='.$this->get_acctnum()
                                .'&sort='.$this->get_arg_value('sort')
                                .'&order='.$this->get_arg_value('order');
***************
*** 969,982 ****
                if ($this->debug_logins > 0) { echo 'mail_msg: end_request: 
ENTERING'.'<br>';}
                if ($this->debug_logins > 2) { echo 'mail_msg: end_request: 
direct access info dump of $this->a  :<pre>'; print_r($this->a) ; echo 
'</pre>';}
                if (($this->get_isset_arg('mailsvr_stream') == True)
                && ($this->get_arg_value('mailsvr_stream') != ''))
                {
!                       if ($this->debug_logins > 0) { echo 'mail_msg: 
end_request: stream exists, logging out'.'<br>';}
!                       $tmp_a = $this->a[$this->acctnum];
!                       
$tmp_a['dcom']->close($this->get_arg_value('mailsvr_stream'));
                        $this->set_arg_value('mailsvr_stream', '');
                }
                if ($this->debug_logins > 0) { echo 'mail_msg: end_request: 
LEAVING'.'<br>';}
!               $this->a[$this->acctnum] = $tmp_a;
        }
                
--- 995,1011 ----
                if ($this->debug_logins > 0) { echo 'mail_msg: end_request: 
ENTERING'.'<br>';}
                if ($this->debug_logins > 2) { echo 'mail_msg: end_request: 
direct access info dump of $this->a  :<pre>'; print_r($this->a) ; echo 
'</pre>';}
+               
                if (($this->get_isset_arg('mailsvr_stream') == True)
                && ($this->get_arg_value('mailsvr_stream') != ''))
                {
!                       if ($this->debug_logins > 0) { echo 'mail_msg: 
end_request: stream exists, logging out'.'<br>'; }
!                       //$tmp_a = $this->a[$this->acctnum];
!                       
//$tmp_a['dcom']->close($this->get_arg_value('mailsvr_stream'));
!                       $this_acctnum = $this->acctnum;
!                       
$GLOBALS['phpgw_dcom_'.$this_acctnum]->dcom->close($this->get_arg_value('mailsvr_stream'));
                        $this->set_arg_value('mailsvr_stream', '');
                }
                if ($this->debug_logins > 0) { echo 'mail_msg: end_request: 
LEAVING'.'<br>';}
!               //$this->a[$this->acctnum] = $tmp_a;
        }
                
***************
*** 1183,1187 ****
                // we *may* need this data later
                $mailsvr_stream = $this->get_arg_value('mailsvr_stream');
!               $server_str = $this->get_pref_value('mailsvr_callstr');
                
                if (($this->get_pref_value('imap_server_type') == 'UW-Maildir')
--- 1212,1216 ----
                // we *may* need this data later
                $mailsvr_stream = $this->get_arg_value('mailsvr_stream');
!               $server_str = $this->get_arg_value('mailsvr_callstr');
                
                if (($this->get_pref_value('imap_server_type') == 'UW-Maildir')
***************
*** 1227,1232 ****
                        // FIXME: abstract this class dcom call in 
mail_msg_wrappers
                        if ($this->debug_args_special_handlers > 1) { echo 
'mail_msg: get_mailsvr_namespace: issuing: 
$this->a['.$this->acctnum.'][dcom]->listmailbox('.$mailsvr_stream.', 
'.$server_str.', %)'.'<br>'; }
!                       $tmp_a = $this->a[$this->acctnum];
!                       $name_space = 
$tmp_a['dcom']->listmailbox($mailsvr_stream, $server_str, '%');
                        if ($this->debug_args_special_handlers > 2) { echo 
'mail_msg: get_mailsvr_namespace: raw $name_space dump<pre>'; 
print_r($name_space); echo '</pre>'; }
                        
--- 1256,1265 ----
                        // FIXME: abstract this class dcom call in 
mail_msg_wrappers
                        if ($this->debug_args_special_handlers > 1) { echo 
'mail_msg: get_mailsvr_namespace: issuing: 
$this->a['.$this->acctnum.'][dcom]->listmailbox('.$mailsvr_stream.', 
'.$server_str.', %)'.'<br>'; }
!                       
!                       //$tmp_a = $this->a[$this->acctnum];
!                       //$name_space = 
$tmp_a['dcom']->listmailbox($mailsvr_stream, $server_str, '%');
!                       $this_acctnum = $this->acctnum;
!                       $name_space = 
$GLOBALS['phpgw_dcom_'.$this_acctnum]->dcom->listmailbox($mailsvr_stream, 
$server_str, '%');
!                       
                        if ($this->debug_args_special_handlers > 2) { echo 
'mail_msg: get_mailsvr_namespace: raw $name_space dump<pre>'; 
print_r($name_space); echo '</pre>'; }
                        
***************
*** 1282,1286 ****
                // cache the result in "level one cache" class var holder
                $this->set_arg_value('mailsvr_namespace', $name_space);
!               $this->a[$this->acctnum] = $tmp_a;
                
                // -----------
--- 1315,1319 ----
                // cache the result in "level one cache" class var holder
                $this->set_arg_value('mailsvr_namespace', $name_space);
!               //$this->a[$this->acctnum] = $tmp_a;
                
                // -----------
***************
*** 1323,1331 ****
                }
                
                if ($this->get_pref_value('imap_server_type') == 'UWash')
                {
                        //$delimiter = '/';
                        //$delimiter = SEP;
! 
                        // UWASH is a filesystem based thing, so the delimiter 
is whatever the system SEP is
                        // unix = /  and win = \ (win maybe even "\\" because 
the backslash needs escaping???
--- 1356,1366 ----
                }
                
+               if ($this->debug_args_special_handlers > 0) { echo 'mail_msg: 
get_mailsvr_delimiter: $this->get_pref_value(imap_server_type) returns: 
['.$this->get_pref_value('imap_server_type').'] ; api var SEP: 
['.serialize(SEP).']<br>'; }
+               
                if ($this->get_pref_value('imap_server_type') == 'UWash')
                {
                        //$delimiter = '/';
                        //$delimiter = SEP;
!                       
                        // UWASH is a filesystem based thing, so the delimiter 
is whatever the system SEP is
                        // unix = /  and win = \ (win maybe even "\\" because 
the backslash needs escaping???
***************
*** 1510,1522 ****
                
                // check if class dcom reports that the folder list has changed
!               $tmp_a = $this->a[$this->acctnum];
! 
!               if ((isset($tmp_a['dcom']))
!               && ($tmp_a['dcom']->folder_list_changed == True))
                {
                        // class dcom recorded a change in the folder list
                        // supposed to happen when create or delete mailbox is 
called
                        // reset the changed flag
!                       $tmp_a['dcom']->folder_list_changed = False;
                        // set up for a force_refresh
                        $force_refresh = True;
--- 1545,1560 ----
                
                // check if class dcom reports that the folder list has changed
!               //$tmp_a = $this->a[$this->acctnum];
!               
!               //if ((isset($tmp_a['dcom']))
!               //&& ($tmp_a['dcom']->folder_list_changed == True))
!               if ((is_object($GLOBALS['phpgw_dcom_'.$this_acctnum]->dcom))
!               && 
($GLOBALS['phpgw_dcom_'.$this_acctnum]->dcom->folder_list_changed == True))
                {
                        // class dcom recorded a change in the folder list
                        // supposed to happen when create or delete mailbox is 
called
                        // reset the changed flag
!                       // $tmp_a['dcom']->folder_list_changed = False;
!                       
$GLOBALS['phpgw_dcom_'.$this_acctnum]->dcom->folder_list_changed = False;
                        // set up for a force_refresh
                        $force_refresh = True;
***************
*** 1618,1622 ****
                        // UWash will consider it relative to the mailuser's 
$HOME property as with "emails/*" (DOES THIS WORK ON ALL PLATFORMS??)
                        // BUT we use <tilde><slash> "~/" if no namespace is 
given
!                       $mailboxes = 
$tmp_a['dcom']->listmailbox($mailsvr_stream, $server_str, "$name_space" 
."$delimiter" ."*");
                        // UWASH IMAP returns information in this format:
                        // {SERVER_NAME:PORT}FOLDERNAME
--- 1656,1661 ----
                        // UWash will consider it relative to the mailuser's 
$HOME property as with "emails/*" (DOES THIS WORK ON ALL PLATFORMS??)
                        // BUT we use <tilde><slash> "~/" if no namespace is 
given
!                       //$mailboxes = 
$tmp_a['dcom']->listmailbox($mailsvr_stream, $server_str, "$name_space" 
."$delimiter" ."*");
!                       $mailboxes = 
$GLOBALS['phpgw_dcom_'.$this_acctnum]->dcom->listmailbox($mailsvr_stream, 
$server_str, "$name_space" ."$delimiter" ."*");
                        // UWASH IMAP returns information in this format:
                        // {SERVER_NAME:PORT}FOLDERNAME
***************
*** 1636,1640 ****
                        // UPDATED information of this issue: to get shared 
folders included in the return, better NOT include the "." delimiter
                        // example: Cyrus does not like anything but a "*" as 
the pattern IF you want shared folders returned.
!                       $mailboxes = 
$tmp_a['dcom']->listmailbox($mailsvr_stream, $server_str, "*");
                        // returns information in this format:
                        // {SERVER_NAME:PORT} NAMESPACE DELIMITER FOLDERNAME
--- 1675,1680 ----
                        // UPDATED information of this issue: to get shared 
folders included in the return, better NOT include the "." delimiter
                        // example: Cyrus does not like anything but a "*" as 
the pattern IF you want shared folders returned.
!                       //$mailboxes = 
$tmp_a['dcom']->listmailbox($mailsvr_stream, $server_str, "*");
!                       $mailboxes = 
$GLOBALS['phpgw_dcom_'.$this_acctnum]->dcom->listmailbox($mailsvr_stream, 
$server_str, "*");
                        // returns information in this format:
                        // {SERVER_NAME:PORT} NAMESPACE DELIMITER FOLDERNAME
***************
*** 1738,1742 ****
                if ($this->debug_args_special_handlers > 2) { echo 'mail_msg: 
get_folder_list: finished, $my_folder_list dump:<pre>'; 
print_r($my_folder_list); echo '</pre>'; }
                if ($this->debug_args_special_handlers > 0) { echo 'mail_msg: 
get_folder_list: LEAVING, got folder data from server<br>'; }
!               $this->a[$this->acctnum] = $tmp_a;
                return $my_folder_list;
        }
--- 1778,1782 ----
                if ($this->debug_args_special_handlers > 2) { echo 'mail_msg: 
get_folder_list: finished, $my_folder_list dump:<pre>'; 
print_r($my_folder_list); echo '</pre>'; }
                if ($this->debug_args_special_handlers > 0) { echo 'mail_msg: 
get_folder_list: LEAVING, got folder data from server<br>'; }
!               //$this->a[$this->acctnum] = $tmp_a;
                return $my_folder_list;
        }

Index: class.mail_msg_display.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware//email/inc/class.mail_msg_display.inc.php,v
retrieving revision 1.26
retrieving revision 1.27
diff -C2 -r1.26 -r1.27
*** class.mail_msg_display.inc.php      7 Jan 2002 10:50:42 -0000       1.26
--- class.mail_msg_display.inc.php      8 Jan 2002 15:06:03 -0000       1.27
***************
*** 944,950 ****
  
                        // TEMPORARY HACK FOR SOCKET POP3 CLASS - feed it DUMB 
mime part numbers
!                       $tmp_a = $this->a[$this->acctnum];
!                       if ((isset($tmp_a['dcom']->imap_builtin))
!                       && ($tmp_a['dcom']->imap_builtin == False)
                        && (stristr($this->get_pref_value('mail_server_type'), 
'pop3')))
                        {
--- 944,953 ----
  
                        // TEMPORARY HACK FOR SOCKET POP3 CLASS - feed it DUMB 
mime part numbers
!                       
!                       //$tmp_a = $this->a[$this->acctnum];
!                       //if ((isset($tmp_a['dcom']->imap_builtin))
!                       //&& ($tmp_a['dcom']->imap_builtin == False)
!                       if 
((isset($GLOBALS['phpgw_dcom_'.$this->acctnum]->dcom->imap_builtin))
!                       && 
($GLOBALS['phpgw_dcom_'.$this->acctnum]->dcom->imap_builtin == False)
                        && (stristr($this->get_pref_value('mail_server_type'), 
'pop3')))
                        {
***************
*** 957,961 ****
                                $part_nice[$i]['m_part_num_mime'] = 
$part_nice[$i]['ex_mime_number_smart'];
                        }
!                       $this->a[$this->acctnum] = $tmp_a;
                        
                        // ------  MAKE CLICKABLE HREF TO THIS PART  -------
--- 960,964 ----
                                $part_nice[$i]['m_part_num_mime'] = 
$part_nice[$i]['ex_mime_number_smart'];
                        }
!                       //$this->a[$this->acctnum] = $tmp_a;
                        
                        // ------  MAKE CLICKABLE HREF TO THIS PART  -------
***************
*** 1705,1711 ****
                        // SKIP this for POP3 - fetchstructure for POP3 
requires download the WHOLE msg
                        // so PHP can build the fetchstructure data (IMAP 
server does this internally)
!                       $tmp_a = $this->a[$this->acctnum];
!                       if ((isset($tmp_a['dcom']->imap_builtin))
!                       && ($tmp_a['dcom']->imap_builtin == False)
                        && (stristr($this->get_pref_value('mail_server_type'), 
'pop3')))
                        {
--- 1708,1717 ----
                        // SKIP this for POP3 - fetchstructure for POP3 
requires download the WHOLE msg
                        // so PHP can build the fetchstructure data (IMAP 
server does this internally)
!                       
!                       //$tmp_a = $this->a[$this->acctnum];
!                       //if ((isset($tmp_a['dcom']->imap_builtin))
!                       //&& ($tmp_a['dcom']->imap_builtin == False)
!                       if 
((isset($GLOBALS['phpgw_dcom_'.$this->acctnum]->dcom->imap_builtin))
!                       && 
($GLOBALS['phpgw_dcom_'.$this->acctnum]->dcom->imap_builtin == False)
                        && (stristr($this->get_pref_value('mail_server_type'), 
'pop3')))
                        {
***************
*** 1721,1725 ****
                                $msg_list_display[$x]['has_attachment'] = 
$this->has_real_attachment($msg_structure);
                        }
!                       $this->a[$this->acctnum] = $tmp_a;
  
                        // Message Information: THE MESSAGE'S HEADERS ENVELOPE 
DATA
--- 1727,1731 ----
                                $msg_list_display[$x]['has_attachment'] = 
$this->has_real_attachment($msg_structure);
                        }
!                       //$this->a[$this->acctnum] = $tmp_a;
  
                        // Message Information: THE MESSAGE'S HEADERS ENVELOPE 
DATA

Index: class.mail_msg_wrappers.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware//email/inc/class.mail_msg_wrappers.inc.php,v
retrieving revision 1.18
retrieving revision 1.19
diff -C2 -r1.18 -r1.19
*** class.mail_msg_wrappers.inc.php     7 Jan 2002 10:50:42 -0000       1.18
--- class.mail_msg_wrappers.inc.php     8 Jan 2002 15:06:03 -0000       1.19
***************
*** 70,79 ****
                        $stream = $this->get_arg_value('mailsvr_stream', 
$acctnum);
                        
!                       $tmp_a = $this->a[$this->acctnum];
!                       $retval = $tmp_a['dcom']->fetchstructure($stream, 
$msgball['msgnum']);
!                       $this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
!       
                /*!
                @function phpgw_header
--- 70,80 ----
                        $stream = $this->get_arg_value('mailsvr_stream', 
$acctnum);
                        
!                       //$tmp_a = $this->a[$this->acctnum];
!                       //$retval = $tmp_a['dcom']->fetchstructure($stream, 
$msgball['msgnum']);
!                       $retval = 
$GLOBALS['phpgw_dcom_'.$acctnum]->dcom->fetchstructure($stream, 
$msgball['msgnum']);
!                       //$this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
!               
                /*!
                @function phpgw_header
***************
*** 100,106 ****
                        
                        // Message Information: THE MESSAGE'S HEADERS RETURNED 
AS A STRUCTURE
!                       $tmp_a = $this->a[$this->acctnum];
!                       $retval = $tmp_a['dcom']->header($stream, 
$msgball['msgnum']);
!                       $this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
--- 101,108 ----
                        
                        // Message Information: THE MESSAGE'S HEADERS RETURNED 
AS A STRUCTURE
!                       //$tmp_a = $this->a[$this->acctnum];
!                       //$retval = $tmp_a['dcom']->header($stream, 
$msgball['msgnum']);
!                       $retval = 
$GLOBALS['phpgw_dcom_'.$acctnum]->dcom->header($stream, $msgball['msgnum']);
!                       //$this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
***************
*** 122,128 ****
                
                        // Message Information: THE MESSAGE'S HEADERS RETURNED 
RAW (no processing)
!                       $tmp_a = $this->a[$this->acctnum];
!                       $retval = $tmp_a['dcom']->fetchheader($stream, 
$msgball['msgnum']);
!                       $this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
--- 124,131 ----
                
                        // Message Information: THE MESSAGE'S HEADERS RETURNED 
RAW (no processing)
!                       //$tmp_a = $this->a[$this->acctnum];
!                       //$retval = $tmp_a['dcom']->fetchheader($stream, 
$msgball['msgnum']);
!                       $retval = 
$GLOBALS['phpgw_dcom_'.$acctnum]->dcom->fetchheader($stream, 
$msgball['msgnum']);
!                       //$this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
***************
*** 137,143 ****
                        else
                        {
!                               $tmp_a = $this->a[$this->acctnum];
!                               $retval = 
$tmp_a['dcom']->get_flag($this->get_arg_value('mailsvr_stream'),$this->get_arg_value('["msgball"]["msgnum"]'),$flag);
!                               $this->a[$this->acctnum] = $tmp_a;
                                return $retval;
                        }
--- 140,147 ----
                        else
                        {
!                               //$tmp_a = $this->a[$this->acctnum];
!                               //$retval = 
$tmp_a['dcom']->get_flag($this->get_arg_value('mailsvr_stream'),$this->get_arg_value('["msgball"]["msgnum"]'),$flag);
!                               $retval = 
$GLOBALS['phpgw_dcom_'.$this->acctnum]->dcom->get_flag($this->get_arg_value('mailsvr_stream'),$this->get_arg_value('["msgball"]["msgnum"]'),$flag);
!                               //$this->a[$this->acctnum] = $tmp_a;
                                return $retval;
                        }
***************
*** 160,166 ****
                        }
                        $stream = $this->get_arg_value('mailsvr_stream', 
$acctnum);
!                       $tmp_a = $this->a[$this->acctnum];
!                       $retval = $tmp_a['dcom']->get_body($stream, 
$msgball['msgnum']);
!                       $this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
--- 164,171 ----
                        }
                        $stream = $this->get_arg_value('mailsvr_stream', 
$acctnum);
!                       //$tmp_a = $this->a[$this->acctnum];
!                       //$retval = $tmp_a['dcom']->get_body($stream, 
$msgball['msgnum']);
!                       $retval = 
$GLOBALS['phpgw_dcom_'.$acctnum]->dcom->get_body($stream, $msgball['msgnum']);
!                       //$this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
***************
*** 189,195 ****
                        $part_no = $msgball['part_no'];
                        //echo 'mail_msg(_wrappers): phpgw_fetchbody: 
processed: $acctnum: '.$acctnum.'; $stream: '.serialize($stream).'; $msgnum: 
'.$msgnum.'; $part_no: '.$part_no.'<br> * $msgball dump<pre>'; 
print_r($msgball); echo '</pre>';
!                       $tmp_a = $this->a[$this->acctnum];
!                       $retval = $tmp_a['dcom']->fetchbody($stream, $msgnum, 
$part_no, $flags);
!                       $this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
--- 194,201 ----
                        $part_no = $msgball['part_no'];
                        //echo 'mail_msg(_wrappers): phpgw_fetchbody: 
processed: $acctnum: '.$acctnum.'; $stream: '.serialize($stream).'; $msgnum: 
'.$msgnum.'; $part_no: '.$part_no.'<br> * $msgball dump<pre>'; 
print_r($msgball); echo '</pre>';
!                       //$tmp_a = $this->a[$this->acctnum];
!                       //$retval = $tmp_a['dcom']->fetchbody($stream, $msgnum, 
$part_no, $flags);
!                       $retval = 
$GLOBALS['phpgw_dcom_'.$acctnum]->dcom->fetchbody($stream, $msgnum, $part_no, 
$flags);
!                       //$this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
***************
*** 250,256 ****
                        {
                                $server_msgnum_list = array();
!                               $tmp_a = $this->a[$this->acctnum];
!                               $server_msgnum_list = 
$tmp_a['dcom']->sort($this->get_arg_value('mailsvr_stream'), 
$this->get_arg_value('sort'), $this->get_arg_value('order'));
!                               $this->a[$this->acctnum] = $tmp_a;
                                // put more information about these particular 
messages into the msgball_list[] structure
                                $msgball_list = array();
--- 256,263 ----
                        {
                                $server_msgnum_list = array();
!                               //$tmp_a = $this->a[$this->acctnum];
!                               //$server_msgnum_list = 
$tmp_a['dcom']->sort($this->get_arg_value('mailsvr_stream'), 
$this->get_arg_value('sort'), $this->get_arg_value('order'));
!                               $server_msgnum_list = 
$GLOBALS['phpgw_dcom_'.$this->acctnum]->dcom->sort($this->get_arg_value('mailsvr_stream'),
 $this->get_arg_value('sort'), $this->get_arg_value('order'));
!                               //$this->a[$this->acctnum] = $tmp_a;
                                // put more information about these particular 
messages into the msgball_list[] structure
                                $msgball_list = array();
***************
*** 294,300 ****
                function get_folder_size()
                {
!                       $tmp_a = $this->a[$this->acctnum];
!                       $mailbox_detail = 
$tmp_a['dcom']->mailboxmsginfo($this->get_arg_value('mailsvr_stream'));
!                       $this->a[$this->acctnum] = $tmp_a;
                        return $mailbox_detail->Size;
                }
--- 301,308 ----
                function get_folder_size()
                {
!                       //$tmp_a = $this->a[$this->acctnum];
!                       //$mailbox_detail = 
$tmp_a['dcom']->mailboxmsginfo($this->get_arg_value('mailsvr_stream'));
!                       $mailbox_detail = 
$GLOBALS['phpgw_dcom_'.$this->acctnum]->dcom->mailboxmsginfo($this->get_arg_value('mailsvr_stream'));
!                       //$this->a[$this->acctnum] = $tmp_a;
                        return $mailbox_detail->Size;
                }
***************
*** 348,355 ****
                        
                        $server_str = $this->get_arg_value('mailsvr_callstr');
!                       $tmp_a = $this->a[$this->acctnum];
!                       $mailbox_status = 
$tmp_a['dcom']->status($this->get_arg_value('mailsvr_stream'),$server_str.$this->get_arg_value('folder'),SA_ALL);
!                       $this->a[$this->acctnum] = $tmp_a;
! 
                        // cache validity data - will be used to cache 
msg_list_array data, which is good until UID_NEXT changes
                        $return_data['uidnext'] = $mailbox_status->uidnext;
--- 356,364 ----
                        
                        $server_str = $this->get_arg_value('mailsvr_callstr');
!                       //$tmp_a = $this->a[$this->acctnum];
!                       //$mailbox_status = 
$tmp_a['dcom']->status($this->get_arg_value('mailsvr_stream'),$server_str.$this->get_arg_value('folder'),SA_ALL);
!                       $mailbox_status = 
$GLOBALS['phpgw_dcom_'.$this->acctnum]->dcom->status($this->get_arg_value('mailsvr_stream'),$server_str.$this->get_arg_value('folder'),SA_ALL);
!                       //$this->a[$this->acctnum] = $tmp_a;
!                       
                        // cache validity data - will be used to cache 
msg_list_array data, which is good until UID_NEXT changes
                        $return_data['uidnext'] = $mailbox_status->uidnext;
***************
*** 403,409 ****
                {
                        $server_str = $this->get_arg_value('mailsvr_callstr');
!                       $tmp_a = $this->a[$this->acctnum];
!                       $retval = 
$tmp_a['dcom']->status($this->get_arg_value('mailsvr_stream'),"$server_str"."$feed_folder_long",SA_ALL);
!                       $this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
--- 412,419 ----
                {
                        $server_str = $this->get_arg_value('mailsvr_callstr');
!                       //$tmp_a = $this->a[$this->acctnum];
!                       //$retval = 
$tmp_a['dcom']->status($this->get_arg_value('mailsvr_stream'),"$server_str"."$feed_folder_long",SA_ALL);
!                       $retval = 
$GLOBALS['phpgw_dcom_'.$this->acctnum]->dcom->status($this->get_arg_value('mailsvr_stream'),"$server_str"."$feed_folder_long",SA_ALL);
!                       //$this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
***************
*** 411,417 ****
                function phpgw_server_last_error()
                {
!                       $tmp_a = $this->a[$this->acctnum];
!                       $retval = $tmp_a['dcom']->server_last_error();
!                       $this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
--- 421,428 ----
                function phpgw_server_last_error()
                {
!                       //$tmp_a = $this->a[$this->acctnum];
!                       //$retval = $tmp_a['dcom']->server_last_error();
!                       $retval = 
$GLOBALS['phpgw_dcom_'.$this->acctnum]->dcom->server_last_error();
!                       //$this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
***************
*** 419,425 ****
                function phpgw_ping()
                {
!                       $tmp_a = $this->a[$this->acctnum];
!                       $retval = 
$tmp_a['dcom']->noop_ping_test($this->get_arg_value('mailsvr_stream'));
!                       $this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
--- 430,437 ----
                function phpgw_ping()
                {
!                       //$tmp_a = $this->a[$this->acctnum];
!                       //$retval = 
$tmp_a['dcom']->noop_ping_test($this->get_arg_value('mailsvr_stream'));
!                       $retval = 
$GLOBALS['phpgw_dcom_'.$this->acctnum]->dcom->noop_ping_test($this->get_arg_value('mailsvr_stream'));
!                       //$this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
***************
*** 427,433 ****
                function phpgw_search($criteria,$flags='')
                {
!                       $tmp_a = $this->a[$this->acctnum];
!                       $retval = 
$tmp_a['dcom']->i_search($this->get_arg_value('mailsvr_stream'),$criteria,$flags);
!                       $this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
--- 439,446 ----
                function phpgw_search($criteria,$flags='')
                {
!                       //$tmp_a = $this->a[$this->acctnum];
!                       //$retval = 
$tmp_a['dcom']->i_search($this->get_arg_value('mailsvr_stream'),$criteria,$flags);
!                       $retval = 
$GLOBALS['phpgw_dcom_'.$this->acctnum]->dcom->i_search($this->get_arg_value('mailsvr_stream'),$criteria,$flags);
!                       //$this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
***************
*** 438,444 ****
                        $stream = $this->get_arg_value('mailsvr_stream', 
$acctnum);
                        $folder = $target_fldball['folder'];
!                       $tmp_a = $this->a[$this->acctnum];
!                       $retval = $tmp_a['dcom']->createmailbox($stream, 
$folder);
!                       $this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
--- 451,458 ----
                        $stream = $this->get_arg_value('mailsvr_stream', 
$acctnum);
                        $folder = $target_fldball['folder'];
!                       //$tmp_a = $this->a[$this->acctnum];
!                       //$retval = $tmp_a['dcom']->createmailbox($stream, 
$folder);
!                       $retval = 
$GLOBALS['phpgw_dcom_'.$acctnum]->dcom->createmailbox($stream, $folder);
!                       //$this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
***************
*** 449,455 ****
                        $stream = $this->get_arg_value('mailsvr_stream', 
$acctnum);
                        $folder = $target_fldball['folder'];
!                       $tmp_a = $this->a[$this->acctnum];
!                       $retval = $tmp_a['dcom']->deletemailbox($stream, 
$folder);
!                       $this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
--- 463,470 ----
                        $stream = $this->get_arg_value('mailsvr_stream', 
$acctnum);
                        $folder = $target_fldball['folder'];
!                       //$tmp_a = $this->a[$this->acctnum];
!                       //$retval = $tmp_a['dcom']->deletemailbox($stream, 
$folder);
!                       $retval = 
$GLOBALS['phpgw_dcom_'.$acctnum]->dcom->deletemailbox($stream, $folder);
!                       //$this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
***************
*** 461,467 ****
                        $folder_old = $source_fldball['folder'];
                        $folder_new = $target_fldball['folder'];
!                       $tmp_a = $this->a[$this->acctnum];
!                       $retval = $tmp_a['dcom']->renamemailbox($stream, 
$folder_old, $folder_new);
!                       $this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
--- 476,483 ----
                        $folder_old = $source_fldball['folder'];
                        $folder_new = $target_fldball['folder'];
!                       //$tmp_a = $this->a[$this->acctnum];
!                       //$retval = $tmp_a['dcom']->renamemailbox($stream, 
$folder_old, $folder_new);
!                       $retval = 
$GLOBALS['phpgw_dcom_'.$acctnum]->dcom->renamemailbox($stream, $folder_old, 
$folder_new);
!                       //$this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
***************
*** 517,523 ****
                                
$this->expire_session_cache_item('msgball_list');
                                // do the append
!                               $tmp_a = $this->a[$this->acctnum];
!                               $retval = 
$tmp_a['dcom']->append($this->get_arg_value('mailsvr_stream'), 
"$server_str"."$official_folder_long", $message, $flags);
!                               $this->a[$this->acctnum] = $tmp_a;
                                return $retval;
                        }
--- 533,540 ----
                                
$this->expire_session_cache_item('msgball_list');
                                // do the append
!                               //$tmp_a = $this->a[$this->acctnum];
!                               //$retval = 
$tmp_a['dcom']->append($this->get_arg_value('mailsvr_stream'), 
"$server_str"."$official_folder_long", $message, $flags);
!                               $retval = 
$GLOBALS['phpgw_dcom_'.$this->acctnum]->dcom->append($this->get_arg_value('mailsvr_stream'),
 "$server_str"."$official_folder_long", $message, $flags);
!                               //$this->a[$this->acctnum] = $tmp_a;
                                return $retval;
                        }
***************
*** 537,543 ****
                        $this->expire_session_cache_item('msgball_list');
                        
!                       $tmp_a = $this->a[$this->acctnum];
!                       $retval = 
$tmp_a['dcom']->mail_move($this->get_arg_value('mailsvr_stream'), $msg_list, 
$mailbox);
!                       $this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
--- 554,561 ----
                        $this->expire_session_cache_item('msgball_list');
                        
!                       //$tmp_a = $this->a[$this->acctnum];
!                       //$retval = 
$tmp_a['dcom']->mail_move($this->get_arg_value('mailsvr_stream'), $msg_list, 
$mailbox);
!                       $retval = 
$GLOBALS['phpgw_dcom_'.$this->acctnum]->dcom->mail_move($this->get_arg_value('mailsvr_stream'),
 $msg_list, $mailbox);
!                       //$this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
***************
*** 564,570 ****
                        // the acctnum we are moving FROM *may* be different 
from the acctnum we are moving TO
                        // that requires a fetch then an append - FIXME!!!
!                       $tmp_a = $this->a[$this->acctnum];
!                       $retval = $tmp_a['dcom']->mail_move($stream ,$msgnum, 
$mailbox);
!                       $this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
--- 582,590 ----
                        // the acctnum we are moving FROM *may* be different 
from the acctnum we are moving TO
                        // that requires a fetch then an append - FIXME!!!
!                       
!                       //$tmp_a = $this->a[$this->acctnum];
!                       //$retval = $tmp_a['dcom']->mail_move($stream ,$msgnum, 
$mailbox);
!                       $retval = 
$GLOBALS['phpgw_dcom_'.$acctnum]->dcom->mail_move($stream ,$msgnum, $mailbox);
!                       //$this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
***************
*** 578,584 ****
                        }
                        $stream = $this->get_arg_value('mailsvr_stream', 
$acctnum);
!                       $tmp_a = $this->a[$this->acctnum];
!                       $retval = $tmp_a['dcom']->expunge($stream);
!                       $this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
--- 598,605 ----
                        }
                        $stream = $this->get_arg_value('mailsvr_stream', 
$acctnum);
!                       //$tmp_a = $this->a[$this->acctnum];
!                       //$retval = $tmp_a['dcom']->expunge($stream);
!                       $retval = 
$GLOBALS['phpgw_dcom_'.$acctnum]->dcom->expunge($stream);
!                       //$this->a[$this->acctnum] = $tmp_a;
                        return $retval;
                }
***************
*** 613,619 ****
                                        
                                        //return imap_delete($stream,$msg_num);
!                                       $tmp_a = $this->a[$this->acctnum];
!                                       $retval = 
$tmp_a['dcom']->delete($stream, $msg_num);
!                                       $this->a[$this->acctnum] = $tmp_a;
                                        return $retval;
                                }
--- 634,641 ----
                                        
                                        //return imap_delete($stream,$msg_num);
!                                       //$tmp_a = $this->a[$this->acctnum];
!                                       //$retval = 
$tmp_a['dcom']->delete($stream, $msg_num);
!                                       $retval = 
$GLOBALS['phpgw_dcom_'.$acctnum]->dcom->delete($stream, $msg_num);
!                                       //$this->a[$this->acctnum] = $tmp_a;
                                        return $retval;
                                }
***************
*** 667,673 ****
                                                // so just straight delete the 
message
                                                //return 
imap_delete($stream,$msg_num);
!                                               $tmp_a = 
$this->a[$this->acctnum];
!                                               $retval = 
$tmp_a['dcom']->delete($this->get_arg_value('mailsvr_stream'), $msg_num);
!                                               $this->a[$this->acctnum] = 
$tmp_a;
                                                return $retval;
                                        }
--- 689,696 ----
                                                // so just straight delete the 
message
                                                //return 
imap_delete($stream,$msg_num);
!                                               //$tmp_a = 
$this->a[$this->acctnum];
!                                               //$retval = 
$tmp_a['dcom']->delete($this->get_arg_value('mailsvr_stream'), $msg_num);
!                                               $retval = 
$GLOBALS['phpgw_dcom_'.$acctnum]->dcom->delete($this->get_arg_value('mailsvr_stream'),
 $msg_num);
!                                               //$this->a[$this->acctnum] = 
$tmp_a;
                                                return $retval;
                                        }
***************
*** 680,686 ****
                                
                                //return imap_delete($stream,$msg_num);
!                               $tmp_a = $this->a[$this->acctnum];
!                               $retval = 
$tmp_a['dcom']->delete($this->get_arg_value('mailsvr_stream'), $msg_num);
!                               $this->a[$this->acctnum] = $tmp_a;
                                return $retval;
                        }
--- 703,710 ----
                                
                                //return imap_delete($stream,$msg_num);
!                               //$tmp_a = $this->a[$this->acctnum];
!                               //$retval = 
$tmp_a['dcom']->delete($this->get_arg_value('mailsvr_stream'), $msg_num);
!                               $retval = 
$GLOBALS['phpgw_dcom_'.$acctnum]->dcom->delete($this->get_arg_value('mailsvr_stream'),
 $msg_num);
!                               //$this->a[$this->acctnum] = $tmp_a;
                                return $retval;
                        }
***************
*** 1593,1600 ****
--- 1617,1626 ----
                function get_pref_value($pref_name='',$acctnum='')
                {
+                       if ($this->debug_args_oop_access > 0) { echo 
'mail_msg(_wrappers): get_pref_value: ENTERING, $pref_name: ['.$pref_name.'] 
$acctnum: ['.$acctnum.']'.'<br>'; }
                        if ((!isset($acctnum))
                        || ((string)$acctnum == ''))
                        {
                                $acctnum = $this->get_acctnum();
+                               if ($this->debug_args_oop_access > 1) { echo 
'mail_msg(_wrappers): get_pref_value: obtained acctnum from 
"$this->get_acctnum()", got $acctnum: ['.$acctnum.']'.'<br>'; }
                        }
                        
***************
*** 1603,1606 ****
--- 1629,1633 ----
                        && (isset($this->a[$acctnum]['prefs'][$pref_name])))
                        {
+                               if ($this->debug_args_oop_access > 0) { echo 
'mail_msg(_wrappers): get_pref_value: LEAVING, returning 
$this->a['.$acctnum.'][prefs]['.$pref_name.'] : 
['.$this->a[$acctnum]['prefs'][$pref_name].'] <br>'; }
                                return $this->a[$acctnum]['prefs'][$pref_name];
                        }
***************
*** 1608,1611 ****
--- 1635,1639 ----
                        {
                                // arg not set, or invalid input $arg_name
+                               if ($this->debug_args_oop_access > 0) { echo 
'mail_msg(_wrappers): get_pref_value: LEAVING with ERRROR, pref item was not 
found<br>'; }
                                return;
                        }




reply via email to

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