Changeset 19004


Ignore:
Timestamp:
Nov 13, 2012, 7:47:49 PM (8 years ago)
Author:
cljosse
Message:

[extensions] mail_superviseur fix compatibility with contactform)

Location:
extensions/Mail_supervisor
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • extensions/Mail_supervisor/mail_send.inc.php

    r13572 r19004  
    6767*************************************/
    6868static public function send_mail_content($content){
     69global $myclContent;
     70$myclContent=$content ;
    6971
    7072return $content;
     
    138140  $cvt_subject = encode_mime_header($cvt_subject);
    139141
    140   if (!isset($args['content']))  {
    141     $args['content'] = '';
    142   }
     142 
    143143
    144144  if (empty($args['content_format']))  {
     
    336336     if(count($content_type_list)>1)
    337337       $content.= $conf_mail[$cache_key]['header'];
     338             
     339             global $myclContent;
     340             if (!isset($args['content']))  {
     341    $args['content'] = '';
     342 
     343
     344             if($myclContent && $myclContent!="" ){
     345                  $args['content'] = "Hello myclContent: ".$myclContent;
     346                  $myclContent="";
     347                  $content_type="";
     348                }
     349     }             
    338350
    339351    // Content
     
    345357                                 htmlspecialchars($args['content']))).
    346358                  '</p>';
    347     }
    348     else if (($args['content_format'] == 'text/html') and ($content_type == 'text/plain'))
    349     {
     359    } else if (($args['content_format'] == 'text/html') and ($content_type == 'text/plain')) {
    350360      // convert html text to plain text
    351361      $content.= strip_tags($args['content']);
     
    353363      $content.= $args['content'];
    354364    }
    355 
     365   
    356366    // Footer
    357367    $content.= $conf_mail[$cache_key]['footer'];
     
    401411
    402412//===========================================
     413
    403414
    404415   // Undo Compute root_path in order have complete path
  • extensions/Mail_supervisor/main.inc.php

    r13572 r19004  
    22/*
    33Plugin Name: Mail supervisor
    4 Version: auto
     4Version: 1.5.8
    55Description: Mail supervisor surveille l'envoie des mails.
    66Plugin URI: http://piwigo.org/ext/extension_view.php?eid=315
     
    5959  include_once (MAIL_SUPERV_PATH.'include/fonctions.php');
    6060  load_language('plugin.lang', MAIL_SUPERV_PATH);
    61 
     61 
    6262  $arg_trigg= array($mailto, $subject, $content, $headers, $args);
    6363    trigger_event('mail_supervisor_clj_mail',$arg_trigg);
Note: See TracChangeset for help on using the changeset viewer.