[limb-svn] r7072 - 3.x/trunk/limb/mail/src

svn at limb-project.com svn at limb-project.com
Wed Jun 25 18:46:00 MSD 2008


Author: korchasa
Date: 2008-06-25 18:45:59 +0400 (Wed, 25 Jun 2008)
New Revision: 7072
URL: http://fisheye.limb-project.com/changelog/limb/?cs=7072

Modified:
   3.x/trunk/limb/mail/src/lmbMailer.class.php
Log:
-- fix relative path in mail package

Modified: 3.x/trunk/limb/mail/src/lmbMailer.class.php
===================================================================
--- 3.x/trunk/limb/mail/src/lmbMailer.class.php	2008-06-25 14:33:29 UTC (rev 7071)
+++ 3.x/trunk/limb/mail/src/lmbMailer.class.php	2008-06-25 14:45:59 UTC (rev 7072)
@@ -6,7 +6,7 @@
  * @copyright  Copyright © 2004-2007 BIT(http://bit-creative.com)
  * @license    LGPL http://www.gnu.org/copyleft/lesser.html
  */
- at define('PHPMAILER_DIR', dirname(__FILE__) . '/../lib/phpmailer-2.1.0.beta2/');
+ at define('PHPMAILER_VERSION_NAME', 'phpmailer-2.1.0.beta2');
 @define('LIMB_USE_PHPMAIL', false);
 @define('LIMB_SMTP_PORT', '25');
 @define('LIMB_SMTP_HOST', 'localhost');
@@ -26,7 +26,7 @@
   protected $images = array();
 
   protected $_config_properties_map = array(
-    'phpmailer_dir' => 'PHPMAILER_DIR',
+    'phpmailer_version_name' => 'PHPMAILER_VERSION_NAME',
     'use_phpmail' => 'LIMB_USE_PHPMAIL',
     'smtp_host' => 'LIMB_SMTP_HOST',
     'smtp_port' => 'LIMB_SMTP_PORT',
@@ -66,7 +66,7 @@
 
   protected function _createMailer()
   {
-    include_once($this->phpmailer_dir . '/class.phpmailer.php');
+    include_once('limb/mail/lib/' .  $this->phpmailer_version_name . '/class.phpmailer.php');
 
     $mailer = new PHPMailer();
     $mailer->set('LE', "\r\n");
@@ -96,7 +96,7 @@
       'type' => $type
     );
   }
-  
+
   function embedImage($path, $cid, $name="", $encoding="base64", $type="application/octet-stream")
   {
     $this->images[] = array(
@@ -120,7 +120,7 @@
 
     if(!empty($this->images))
       $this->_addEmbeddedImages($mailer);
-      
+
     $recipients = $this->processMailRecipients($recipients);
 
     foreach($recipients as $recipient)
@@ -151,7 +151,7 @@
 
     if(!empty($this->images))
       $this->_addEmbeddedImages($mailer);
-      
+
     if(!is_null($text))
       $mailer->AltBody = $text;
 
@@ -208,7 +208,7 @@
                              $attachment['encoding'],
                              $attachment['type']);
   }
-  
+
   protected function _addEmbeddedImages($mailer)
   {
     foreach ($this->images as $image)



More information about the limb-svn mailing list