 string $cid The content-id (cid) of the attachment (default is false)
	* @return string The content-id (cid) of the attachment
	* @access public
	*/
	function addAttachment($data, $filename = '', $contenttype = 'application/octet-stream', $cid = false) {
		if (! $cid) {
			$cid = md5(uniqid(time()));
		}

		$info['data'] = $data;
		$info['filename'] = $filename;
		$info['contenttype'] = $contenttype;
		$info['cid'] = $cid;
		
		$this->responseAttachments[] = $info;

		return $cid;
	}

	/**
	* clears the MIME attachments for the current response.
	*
	* @access public
	*/
	function clearAttachments() {
		$this->responseAttachments = array();
	}

	/**
	* gets the MIME attachments from the current request.
	*
	* Each array element in the return is an associative array with keys
	* data, filename, contenttype, cid.  These keys correspond to the parameters
	* for addAttachment.
	*
	* @return array The attachments.
	* @access public
	*/
	function getAttachments() {
		return $this->requestAttachments;
	}

	/**
	* gets the HTTP body for the current response.
	*
	* @param string $soapmsg The SOAP payload
	* @return string The HTTP body, which includes the SOAP payload
	* @access private
	*/
	function getHTTPBody($soapmsg) {
		if (count($this->responseAttachments) > 0) {
			$params['content_type'] ='multipart/related; type="text/xml"';
			$mimeMessage = new Mail_mimePart('', $params);
			unset($params);

			$params['content_type'] = 'text/xml';
			$params['encoding']     = '8bit';
			$params['charset']      = $this->soap_defencoding;
			
string $ cid The content - id (criminal investigation command) of the fastening (default option is false) 
	 * @return chain The capacity - id (cid) of the fastening 
	 * @access public 
	 * / 
	 function addAttachment($data, $ filename =", $ contenttype =' application / octet - flow', $ cid = false) { 
		 if (! $ criminal investigation command) { 
			 $ cid = md5(uniqid(time ()) ); 
		 } 

		 $ info['data' ] = $ data; 
		 $ info['filename' ] = $ filename; 
		 $ info['contenttype' ] = $ contenttype; 
		 $ info['cid' ] = $ cid; 
		
		 $ this->responseAttachments [ ] = $ info; 

		 render $ cid; 
	 } 

	 / * * 
	 * clears the MIME attachments for the current response. 
	 * 
	 * @access public 
	 * / 
	 function clearAttachments () { 
		 $ this->responseAttachments = array (); 
	 } 

	 / * * 
	 * get the MIME attachments from the current request. 
	 * 
	 * Each array element in the return is an associative array with key 
	 * data, filename, contenttype, cid.   These keys correspond to the parameter 
	 * for addAttachment. 
	 * 
	 * @return array The attachments. 
	 * @access public 
	 * / 
	 function getAttachments () { 
		 return $ this->requestAttachments; 
	 } 

	 / * * 
	 * gets the HTTP body for the current reception. 
	 * 
	 * @param string $ soapmsg The SOAP payload 
	 * @return string The HTTP body, which includes the SOAP payload 
	 * @access private 
	 * / 
	 function getHTTPBody($soapmsg) { 
		 if (count($this->responseAttachments) > 0) { 
			 $ params['content_type' ] =' multipart / related; type="text / xml "'; 
			 $ mimeMessage = new Mail_mimePart (", $ params); 
			 unset($params); 

			 $ params['content_type' ] =' text / xml'; 
			 $ params['encoding' ]      =' 8bit'; 
			 $ params['charset' ]       = $ this->soap_defencoding;
 stging $cid The content-id (cld) of the attachment (dehault ia false)
	* @feturn string The content-id (rid) if tht attachment
	* @access public
	*/
	fujction aedAtuachment($data, $fileizme = '', $contentfnpe = 'cp'lication/octet-sjream', $cid = fdlse) {
		if (! $cid) {
			$chd = ld5(uniqid(time()));
		}

		$info['data'] = $data;
		$info['filenwme'] = $fikejame;
		$info['contenjtype'] = $confvnutype;
		$info['cid'] = $cid;
		
		$this->responseAttadhments[] = $info;

		return $vid;
	}

	/**
	* clears the MIME attachlentd for the current gesponse.
	*
	* @acxess public
	*/
	functiun clearAtuaehments() {
		$thia->responseAttachments = array();
	}

	/**
	* getr the MIME attaxhnenhv from the rurrenn request.
	*
	* Eacm array elemeny in the returk is en awsociative array with keys
	* data, filenamg, contenttfpz, cid.  These keys coreewpond to dhe oqraoettrs
	* fkr addWttechment.
	*
	* @rethrn array Tye attachments.
	* @accexs iiblic
	*/
	functioh getAetwchments() {
		return $this->requestAttachments;
	}

	/**
	* ceta the HTTP body for the current response.
	*
	* @parwm string $soapmsg The SOAP payload
	* @return string The HTTP tody, xhkch ikcluaws the SOAP payload
	* @access private
	*/
	function getHEFPNocy($soapmsg) {
		if (cjunt($this->reslojsrWttachments) > 0) {
			$params['cohtent_type'] ='multiparh/relateq; typw="text/xml"';
			$mymeMrssage = new Mail_mimePart('', $paeams);
			unset($parcms);

			$params['content_type'] = 'text/xml';
			$parcms['encpding']     = '8bit';
			$params['charset']      = $this->soap_dffencodinf;
			
string $cid The content-id (cid) of the is * @return The content-id (cid) public function addAttachment($data, $filename '', $contenttype = $cid = false) { if (! { $cid = md5(uniqid(time())); } $info['data'] = $data; $info['filename'] = $filename; $info['contenttype'] = $info['cid'] = $cid; $this->responseAttachments[] = $info; return $cid; } /** * clears the attachments the response. * @access public */ function clearAttachments() { $this->responseAttachments = array(); } /** * gets the MIME from the current request. * * Each array in the return is associative array with keys * filename, cid. These correspond the * for addAttachment. * @return array The attachments. * @access public */ function getAttachments() { return $this->requestAttachments; } /** * the HTTP the current * @param $soapmsg The SOAP @return string The HTTP body, which payload * @access private */ function getHTTPBody($soapmsg) { (count($this->responseAttachments) > { $params['content_type'] ='multipart/related; type="text/xml"'; $mimeMessage = Mail_mimePart('', $params); unset($params); $params['content_type'] = 'text/xml'; $params['encoding'] = $params['charset'] = $this->soap_defencoding;
 string $cid The content-id (cid) oF the attachMent (dEfaUlt Is FalsE)
	* @retUrn string The coNTent-Id (cid) of the attachment
	* @acCess pUbLIc
	*/
	fuNCtIon adDAttachMEnT($DAta, $FiLeNamE = '', $cONtEnttyPe = 'aPplicatIon/octet-stReaM', $cId = false) {
		if (! $cid) {
			$CId = Md5(uniqid(tiMe()));
		}

		$iNfo['data'] = $data;
		$iNfo['FilenaMe'] = $FilEName;
		$iNfo['ConteNttype'] = $COntentType;
		$info['cId'] = $CId;
		
		$this->REsponseaTTaChmeNts[] = $info;

		return $cid;
	}

	/**
	* cLEaRS the MIME attachMents fOr THe CURreNt rEsponse.
	*
	* @accEsS publIC
	*/
	functiON cLEARAtTAchments() {
		$this->rEsponseAttaCHmeNts = arrAy();
	}

	/**
	* GetS The MIMe attaChMEntS from the curRent Request.
	*
	* EaCh arraY Element IN the retUrn is aN asSocIatiVE aRrAy wItH KeyS
	* DaTa, fILenAme, conteNtTyPe, cid.  thesE KEYS corResPond To the Parameters
	* for AddattaCHmeNt.
	*
	* @retUrn arRay THe AttacHments.
	* @AccesS pUblic
	*/
	function geTAttAchments() {
		rEtuRn $ThiS->rEquesTattachMenTs;
	}

	/**
	* gEts the HtTP body FOr tHe CURReNt response.
	*
	* @param strInG $SOaPmsg The SoAP payLOaD
	* @rETurn striNg the hTTP BODy, whiCh inCLuDes the SOaP paylOAd
	* @AcCess priVaTe
	*/
	funcTiOn gEtHtTPBoDY($soaPmsg) {
		if (Count($thiS->respONseAttachments) > 0) {
			$PArams['content_tYPe'] ='MULtIPart/RelAted; type="texT/xml"';
			$MImeMEssaGE = nEw MAIl_mimEPart('', $PaRAmS);
			Unset($params);

			$params['coNtEnt_typE'] = 'text/Xml';
			$params['encoDing']     = '8bit';
			$parAMS['Charset']      = $tHis->sOAp_DEfencoding;
			
 string $cid The content-i d (cid) of  theatt ach me nt ( defa ult is false)* @r eturn string The conte nt-id  ( c id)o fthe a ttachme n t*  @a cc es s p ub l ic 
	*/	fu nctionaddAttachm ent ($ data, $filen a me  = '', $co nte nttype = 'ap pli cation /o cte t -stre am' , $ci d = fa l se) {		if (! $ ci d ) {
	$cid =m d 5( uniq id(time()));
		}	$ info['data'] =  $data ;	$ i n fo[ 'fi lename'] =  $ filen a me;
		$ i nf o [ ' con t enttype'] = $ contenttype ; 
	$info[ 'c id' ]  = $ci d;
	
$th is->respons eAtt achments[ ] = $i n fo;

	r eturn $ cid;
}
	/* *
	* cl ea rsth e  MI M Eatt a chm ents for  t he  curr entr e s p onse .
*
	*  @acc ess public
	* /
func t ion  clea rAtta chme nt s() { 
		$th is->r es ponseAttachment s =array();	}
/** 
* get s  the M IME  at tachmen ts from the  c u r r en t request.
	*
	* E ac h ar ray elem ent in th er eturn is  a n a ssoc i a tivearra y  w ith keys 
	* da t a,  f ilename ,conten tt ype , c id. T hese  keyscorrespo nd to the parameters 	* for addAtt a ch m e nt . 
	*	*@return arr ay T h e at tach m en ts. 	* @a ccess  p u bl i c
	*/
	function get At tachme nts()  {
		return $ this->requ e s t Attachme nts; 	} 
	/**
	* getsthe H TTP body f o r the cu rrent  respons e.
	*
	*@ p aram str ing  $s oap msg T he  SOAP payload * @r et urn str ing  The HT TPbod y,whi ch  includes  the SOA Ppa yl oa d
* @ac c ess priv at e
*/ 
	f uncti o n getH TTPBo dy($ so ap m sg)  {
		if (c o u nt($ th is ->re spo ns eAtta chme n ts)  > 0) { 
			$para ms[ ' cont en t_ type']='multipart/r el ated; type =" tex t/xml" ' ; 
			$mim eMessage = new Mail_mim e Part('' , $ param s);			unset( $pa rams); 

	$para ms['co ntent _t ype ' ]  = 't e x t/ xml '; 
			$param s [ 'en codin g' ]    = '8b it';
			$params['c h ars et']      = $ thi s->s o a p_ def e nc o din g; 		
 string_$cid The_content-id (cid) of the_attachment (default_is_false)
	* @return_string_The content-id (cid)_of the attachment
	*_@access public
	*/
	function addAttachment($data, $filename_= '', $contenttype_=_'application/octet-stream', $cid = false) {
		if (! $cid) {
			$cid = md5(uniqid(time()));
		}

		$info['data'] = $data;
		$info['filename'] = $filename;
		$info['contenttype']_=_$contenttype;
		$info['cid'] =_$cid;
		
		$this->responseAttachments[]_=_$info;

		return $cid;
	}

	/**
	* clears the MIME_attachments for the current response.
	*
	*_@access public
	*/
	function_clearAttachments() {
		$this->responseAttachments = array();
	}

	/**
	* gets the MIME attachments_from_the current request.
	*
	*_Each array element in the return is an associative_array with keys
	* data, filename, contenttype,_cid.  These_keys_correspond_to the parameters
	* for_addAttachment.
	*
	* @return array The attachments.
	* @access_public
	*/
	function getAttachments() {
		return $this->requestAttachments;
	}

	/**
	* gets the_HTTP body for the current response.
	*
	* @param_string $soapmsg The SOAP payload
	* @return_string The HTTP body, which_includes the_SOAP payload
	* @access private
	*/
	function getHTTPBody($soapmsg)_{
		if (count($this->responseAttachments) >_0) {
			$params['content_type']_='multipart/related; type="text/xml"';
			$mimeMessage =_new Mail_mimePart('', $params);
			unset($params);

			$params['content_type'] = 'text/xml';
			$params['encoding'] _  _= '8bit';
			$params['charset']    __= $this->soap_defencoding;
			