Re: Mail/mime.php changes

From: Date: Sun, 16 Sep 2001 18:00:50 +0000
Subject: Re: Mail/mime.php changes
References: 1  Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-1954@lists.php.net to get a copy of this message
Richard Heyes wrote: > > The changes I've made are available here: > > http://www.heyes-computing.net/pear.mime/ > Gooood :-) Aside from the Jon comments I'd like to comment two things: 1) In get(): // Called with neither text or html set } else { return new PEAR_Error('get() called with nothing to build. Try using setTXTBody() or setHTMLBody() first'); } What about if I only want to send attachments? IMO this would be allowed. Just for your information, the error should be thrown with raiseError(), so user of the class can set an especial error handler for the class ($mime->setErrorHandling()) or don't break their apps if they set a global error handler (PEAR::setErrorHandling()). 2) In _buildHtml(): if (!isset($this->_txtbody)) $this->_txtbody = 'No text version was supplied'; Is this message really clear for "normal" people? I'll prefer not to show any message (or even don't parse this part as many clients do) or perhaps give a message like "This is an HTML e-mail with no text version" (if there is HTML version). Please commit the diff, I can help you with the style things if you want. Tomas V.V.Cox

« previous php.pear.dev (#1954) next »