Ignore:
Timestamp:
06/14/12 18:16:02 (12 years ago)
Author:
eduardow
Message:

Ticket #2857 - Problema de formatação de emails criados no expresso e abertos em outros clientes.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2.4/expressoMail1_2/inc/class.imap_functions.inc.php

    r6450 r6505  
    30353035 
    30363036            if ($isHTML) 
     3037            {  
     3038                $this->rfc2397ToEmbeddedAttachment($mailService , $body);  
     3039         
     3040                require_once(dirname(__FILE__).'/../../library/CssToInlineStyles/css_to_inline_styles.php');  
     3041                $defaultStyle = '.expressoDefaultFont{';  
     3042                  
     3043                if(isset($_SESSION['phpgw_info']['user']['preferences']['expressoMail']['font_family_editor']) && $_SESSION['phpgw_info']['user']['preferences']['expressoMail']['font_family_editor'])  
     3044                $defaultStyle .= ' font-family:'.$_SESSION['phpgw_info']['user']['preferences']['expressoMail']['font_family_editor'] .';';  
     3045                                  
     3046                if(isset($_SESSION['phpgw_info']['user']['preferences']['expressoMail']['font_size_editor']) && $_SESSION['phpgw_info']['user']['preferences']['expressoMail']['font_size_editor'])  
     3047                $defaultStyle .= ' font-size:'.$_SESSION['phpgw_info']['user']['preferences']['expressoMail']['font_size_editor'].';';  
     3048                         
     3049                $defaultStyle .= '}';  
     3050         
     3051                $cssToInlineStyles = new CSSToInlineStyles('<span class="expressoDefaultFont">'.$body.'</span>');  
     3052                $cssToInlineStyles->setUseInlineStylesBlock(true);  
     3053                $cssToInlineStyles->setCSS($defaultStyle);  
     3054                $cssToInlineStyles->setCleanup(TRUE);  
     3055                $body = $cssToInlineStyles->convert(); //Converte as tag style em inline styles  
     3056                unset($cssToInlineStyles);  
     3057                  
    30373058                $mailService->setBodyHtml($body); 
     3059             } 
    30383060            else 
    30393061                $mailService->setBodyText($body); 
Note: See TracChangeset for help on using the changeset viewer.