mirror of
				https://git.code.sf.net/p/seeddms/code
				synced 2025-10-31 05:11:27 +00:00 
			
		
		
		
	Merge branch 'seeddms-5.0.x' into seeddms-5.1.x
This commit is contained in:
		
						commit
						9801f5e481
					
				|  | @ -82,10 +82,15 @@ class SeedDMS_EmailNotify extends SeedDMS_Notify { | ||||||
| 			return false; | 			return false; | ||||||
| 		} | 		} | ||||||
| 
 | 
 | ||||||
|  | 		$returnpath = ''; | ||||||
| 		if(is_object($sender) && !strcasecmp(get_class($sender), $this->_dms->getClassname('user'))) { | 		if(is_object($sender) && !strcasecmp(get_class($sender), $this->_dms->getClassname('user'))) { | ||||||
| 			$from = $sender->getFullName() ." <". $sender->getEmail() .">"; | 			$from = $sender->getFullName() ." <". $sender->getEmail() .">"; | ||||||
|  | 			if($this->from_address) | ||||||
|  | 				$returnpath = $this->from_address; | ||||||
| 		} elseif(is_string($sender) && trim($sender) != "") { | 		} elseif(is_string($sender) && trim($sender) != "") { | ||||||
| 			$from = $sender; | 			$from = $sender; | ||||||
|  | 			if($this->from_address) | ||||||
|  | 				$returnpath = $this->from_address; | ||||||
| 		} else { | 		} else { | ||||||
| 			$from = $this->from_address; | 			$from = $this->from_address; | ||||||
| 		} | 		} | ||||||
|  | @ -96,6 +101,8 @@ class SeedDMS_EmailNotify extends SeedDMS_Notify { | ||||||
| 
 | 
 | ||||||
| 		$headers = array (); | 		$headers = array (); | ||||||
| 		$headers['From'] = $from; | 		$headers['From'] = $from; | ||||||
|  | 		if($returnpath) | ||||||
|  | 			$headers['Return-Path'] = $returnpath; | ||||||
| 		$headers['To'] = $to; | 		$headers['To'] = $to; | ||||||
| 		$preferences = array("input-charset" => "UTF-8", "output-charset" => "UTF-8"); | 		$preferences = array("input-charset" => "UTF-8", "output-charset" => "UTF-8"); | ||||||
| 		$encoded_subject = iconv_mime_encode("Subject", getMLText($subject, $params, "", $lang), $preferences); | 		$encoded_subject = iconv_mime_encode("Subject", getMLText($subject, $params, "", $lang), $preferences); | ||||||
|  | @ -125,22 +132,6 @@ class SeedDMS_EmailNotify extends SeedDMS_Notify { | ||||||
| 		} else { | 		} else { | ||||||
| 			return true; | 			return true; | ||||||
| 		} | 		} | ||||||
| 
 |  | ||||||
| /* |  | ||||||
| 		$headers   = array(); |  | ||||||
| 		$headers[] = "MIME-Version: 1.0"; |  | ||||||
| 		$headers[] = "Content-type: text/plain; charset=utf-8"; |  | ||||||
| 		$headers[] = "From: ". $from; |  | ||||||
| 
 |  | ||||||
| 		$lang = $recipient->getLanguage(); |  | ||||||
| 		$message = getMLText("email_header", array(), "", $lang)."\r\n\r\n".getMLText($message, $params, "", $lang); |  | ||||||
| 		$message .= "\r\n\r\n".getMLText("email_footer", array(), "", $lang); |  | ||||||
| 
 |  | ||||||
| 		$subject = "=?UTF-8?B?".base64_encode(getMLText($subject, $params, "", $lang))."?="; |  | ||||||
| 		mail($recipient->getEmail(), $subject, $message, implode("\r\n", $headers)); |  | ||||||
| 
 |  | ||||||
| 		return true; |  | ||||||
| */ |  | ||||||
| 	} /* }}} */ | 	} /* }}} */ | ||||||
| 
 | 
 | ||||||
| 	function toGroup($sender, $groupRecipient, $subject, $message, $params=array()) { /* {{{ */ | 	function toGroup($sender, $groupRecipient, $subject, $message, $params=array()) { /* {{{ */ | ||||||
|  |  | ||||||
|  | @ -746,7 +746,7 @@ if(!is_writeable($settings->_configFilePath)) { | ||||||
| <?php | <?php | ||||||
| 					foreach($extconf['config'] as $confkey=>$conf) { | 					foreach($extconf['config'] as $confkey=>$conf) { | ||||||
| ?>
 | ?>
 | ||||||
|       <tr title="<?php echo $conf['help'];?>"> |       <tr title="<?php echo isset($conf['help']) ? $conf['help'] : '';?>"> | ||||||
|         <td><?php echo $conf['title'];?>:</td><td>
 |         <td><?php echo $conf['title'];?>:</td><td>
 | ||||||
| <?php | <?php | ||||||
| 						switch($conf['type']) { | 						switch($conf['type']) { | ||||||
|  | @ -826,7 +826,7 @@ if(!is_writeable($settings->_configFilePath)) { | ||||||
| 								break; | 								break; | ||||||
| 							default: | 							default: | ||||||
| ?>
 | ?>
 | ||||||
|         <input type="text" name="<?php echo "extensions[".$extname."][".$confkey."]"; ?>" title="<?php echo isset($conf['help']) ? $conf['help'] : ''; ?>" value="<?php if(isset($settings->_extensions[$extname][$confkey])) echo $settings->_extensions[$extname][$confkey]; ?>" size="<?php echo $conf['size']; ?>" /> |         <input type="text" name="<?php echo "extensions[".$extname."][".$confkey."]"; ?>" title="<?php echo isset($conf['help']) ? $conf['help'] : ''; ?>" value="<?php if(isset($settings->_extensions[$extname][$confkey])) echo $settings->_extensions[$extname][$confkey]; ?>" <?php echo isset($conf['size']) ? 'size="'.$conf['size'].'"' : ""; ?>" />
 | ||||||
| <?php | <?php | ||||||
| 						} | 						} | ||||||
| ?>
 | ?>
 | ||||||
|  |  | ||||||
		Loading…
	
		Reference in New Issue
	
	Block a user
	 Uwe Steinmann
						Uwe Steinmann