MailFolderMessage.object
上传用户:xiao730204
上传日期:2007-01-04
资源大小:141k
文件大小:1k
- <?php
- class MailFolderMessage extends BaseObject {
- var $parts;
- var $imap_body_types;
- var $imap_encoding_types;
- var $current_depth;
- var $attatchments;
- Function MailFolderMessage() {
- $this->BaseObject( 'MailFolderMessage' );
- $this->attatchments = Array();
- $this->current_depth = 0;
- $this->imap_body_types = Array(
- 0 => 'Text',
- 1 => 'multiple part',
- 2 => 'encapsulated message',
- 3 => 'application data',
- 4 => 'audio',
- 5 => 'static image',
- 6 => 'video',
- 7 => 'model',
- 8 => 'unknown',
- 15 => 'MAX TYPE',
- '' => 'Text'
- );
- $this->imap_encoding_types = Array(
- 0 => '7BIT',
- 1 => '8BIT',
- 2 => 'BINARY',
- 3 => 'BASE64',
- 4 => 'QUOTED-PRINTABLE',
- 5 => 'X-UNKNOWN'
- );
- }
- Function FormatHeaders( $headers, $new_line = "n" ) {
- if ( $headers == '' ) {
- return 0;
- }
- $header_array = explode( $this->new_line, $headers );
- for( $i = 0; $i < count( $header_array ); $i++ ) {
- if ( ereg( '^(.*): (.*)', $this_line, $regs ) ) {
- $this->$regs[ 1 ] = $regs[ 2 ];
- } else {
- $this->$regs[ 1 ] = $this_line;
- }
- }
- return 1;
- }
- Function FormatImapFetchStructure() {
- }
- }
- ?>