| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788 | <?phpif (!class_exists("plug_mail")) {	class plug_mail {		function __construct($ns) {			$this->title = __("mail", "dagsopt");			$this->pluginname = $ns->pluginname;			$this->file = $ns->file;			$this->ns = $ns;		}		function start() {			$this->logfile = fopen(ABSPATH . "/wp-content/uploads/maillog.log", 'a');			add_filter('wp_mail', array(&$this, 'mail_logger'), 10, 1);		}		function mail_logger($args) {			$str = date("Y-m-d");			$str .= " | " . date("H:i:s");			$str .= " | " . $args['to'];			$str .= " | " . $args['subject'];			fwrite($this->logfile, $str . "\n");			return $args;		}		function help() {			?>				<?php echo (__("Adds mail log functions", "dagsopt")) ?> 			<?php}		function Option($pre) {			//	update_option($pre . '_support_splash', $_POST[$pre . '_support_splash']);		}		function fullscreen() {			?>		 	<?php$data = file_get_contents(ABSPATH . "/wp-content/uploads/maillog.log");			?>	<table class="form-table">			<tr><td style="width: 100px;">Email log</td>				<td>			<textarea class="" rows="40" style="width: 100%; font-size: 11px;"><?php echo ($data) ?></textarea></td></tr>	 		</table>		  <?php		}		function admin_line($pre) {			?>		 <hr>		 <a href="/wp-admin/admin.php?page=dagsopt-options-mail">Se log</a>		  <?php}	}	global $plug_mail;	$plug_mail = new plug_mail($this);	$this->dagsopt['plug_mail'] = $plug_mail;}
 |