WordPress.org

Plugin Directory

Changeset 422932


Ignore:
Timestamp:
08/13/11 15:29:37 (3 years ago)
Author:
wojtek.szkutnik
Message:

0.2

Location:
enhanced-emails/trunk
Files:
1 added
12 edited

Legend:

Unmodified
Added
Removed
  • enhanced-emails/trunk/enhancedemails.php

    r413849 r422932  
    33Plugin Name: Enhanced Emails 
    44Plugin URI: http://wojtekszkutnik.com 
    5 Description: The enhanced emails plugin allows users to send html-enriched emails and use email themes. 
    6 Version: 0.1 
     5Description: The Enhanced Emails plugin adds e-mail themes, HTML versions for custom and default e-mails and easier use of enriched e-mails out of the box. 
     6Version: 0.2 
    77Author: Wojtek Szkutnik 
    88Author URI: http://wojtekszkutnik.com 
     
    5959    // echo the field 
    6060    ?> 
    61  <input id='eemails_use_html' name='eemails_use_html' 
    62  type='checkbox' value="1" <?php checked('1', $value); ?>' /> Use HTML emails 
     61 <input id='eemails_use_html' name='eemails_use_html' type='checkbox' value="1" <?php checked('1', $value); ?> /> Use HTML emails 
    6362    <?php 
    6463} 
     
    8786     
    8887    // Try the theme template dirs 
    89     $template_file = '';#eemails_get_template_from_dir( $template_name ); 
    90      
     88    $template_file = eemails_get_template_from_dir( $template_name ); 
    9189    // Then the wp content dir 
    92     if ( 0 && ! $template_file ) 
     90    if ( '' == $template_file ) 
    9391        $template_file = eemails_get_template_from_dir( $template_name, WP_CONTENT_DIR ); 
    9492         
    9593    // Then the default plugin templates folder 
    96     if ( ! $template_file ) 
     94    if ( '' == $template_file ) 
    9795        $template_file = eemails_get_template_from_dir( $template_name, EEMAILS_TEMPLATES_PATH ); 
    9896         
     
    152150 
    153151 
    154 function eemails_wp_mail( $to, $subject, $message, $args = array() ) { 
     152function eemails_wp_mail( $to, $subject, $message, $headers = '', $attachments = array(), $args = array() ) { 
    155153    $defaults = array ( 
    156         'headers' => '', 
    157         'attachments' => array(), 
    158154        'template' => 'email', 
    159155        'template_args' => array(), 
     
    172168     
    173169    $template = eemails_get_template($template); 
    174      
    175     ob_start(); 
    176     @include( $template ); 
     170    $html_email = ''; 
     171    include( 'templates/layout.php' ); 
    177172    $message = array(  
    178173                     'text/plain' => $message, 
    179                      'text/html' =>ob_get_contents() 
     174                     'text/html' => $html_email 
    180175                    ); 
    181     ob_end_clean(); 
    182176     
    183177    return wp_mail( $to, $subject, $message ); 
  • enhanced-emails/trunk/pluggable.php

    r413849 r422932  
    424424    $subject = apply_filters('comment_notification_subject', $subject, $comment_id); 
    425425    $message_headers = apply_filters('comment_notification_headers', $message_headers, $comment_id); 
    426     $eemails_args['headers'] = $message_headers; 
    427426    $eemails_args['template'] = 'email-comment-notify'; 
    428     @eemails_wp_mail( $author->user_email, $subject, $notify_message, $eemails_args ); 
    429  
     427    @eemails_wp_mail( $author->user_email, $subject, $notify_message, $message_headers, array(), $eemails_args ); 
    430428    return true; 
    431429} 
     
    530528    $message_headers = apply_filters('comment_moderation_headers', $message_headers); 
    531529     
    532     $eemails_args['headers'] = $message_headers; 
    533530    $eemails_args['template'] = 'email-comment-notify'; 
    534531    foreach ( $email_to as $email ) 
    535         @eemails_wp_mail($email, $subject, $notify_message, $eemails_args); 
     532        @eemails_wp_mail($email, $subject, $notify_message, $message_headers, array(), $eemails_args); 
    536533 
    537534    return true; 
     
    562559                                              array('link'=>admin_url("users.php"),'color'=>'3ca757','text'=>__('See all users')) 
    563560                                              ); 
    564         eemails_wp_mail(get_option('admin_email'), sprintf(__('[%s] Password Lost/Changed'), $blogname), $message, $eemail_args); 
     561        eemails_wp_mail(get_option('admin_email'), sprintf(__('[%s] Password Lost/Changed'), $blogname), $message, '', array(), $eemail_args); 
    565562    } 
    566563} 
     
    596593                                          array('link'=>admin_url("users.php"),'color'=>'3ca757','text'=>__('See all users')) 
    597594                                        ); 
    598     @eemails_wp_mail(get_option('admin_email'), sprintf(__('[%s] New User Registration'), $blogname), $message, $eemail_args); 
     595    @eemails_wp_mail(get_option('admin_email'), sprintf(__('[%s] New User Registration'), $blogname), $message, '', array(), $eemail_args); 
    599596 
    600597    if ( empty($plaintext_pass) ) 
     
    608605    $message .= wp_login_url() . "\r\n"; 
    609606 
    610     eemails_wp_mail($user_email, sprintf(__('[%s] Your username and password'), $blogname), $message, $eemail_args); 
     607    eemails_wp_mail($user_email, sprintf(__('[%s] Your username and password'), $blogname), $message, '', array(), $eemail_args); 
    611608 
    612609} 
  • enhanced-emails/trunk/readme.txt

    r413849 r422932  
    11=== Enhanced Emails === 
    22Contributors: wojtek.szkutnik 
    3 Tags: emails 
     3Tags: emails, html 
     4Requires at least: 2.7 
    45Tested up to: 3.2 
     6Stable tag:  0.2 
    57 
    68The enhanced emails plugin allows users to send html-enriched emails and use email themes. 
     
    1214== Installation == 
    1315 
    14 1. Upload `enhancedemails.php` to the `/wp-content/plugins/` directory 
     161. Upload the `enhancedemails` folder to `/wp-content/plugins/` 
    15172. Activate the plugin through the 'Plugins' menu in WordPress 
     18 
     19== Frequently Asked Questions == 
     20 
     21= Will the plugin break my current site? = 
     22 
     23This is highly unlikely to happen. The plugin enhances the way WordPress handles e-mail notifications, but it does it in a unobtrusive way. Basically, it provides a wrapper for wp_mail, which can be used for e-mail notifications. If you did override any pluggable email notification functions, make sure to use eemails_wp_mail instead of wp_mail in order to make use of the plugin functionality.  
     24 
     25= How can I create my own e-mail theme? - 
     26 
     27It's easy - just put your email.php theme file inside your current WP theme directory (if you put it inside wp-content it should work as well, but it's bad practice).  
     28 
     29= How does template hierarchy work for e-mails? = 
     30 
     31An example email template name looks like this: email-action1-action2. The plugin tries to locate email-action1-action2.php in your theme folder, and if it fails - it tries to use email.php from your theme. If this fails, too, the plugin will use its default email-action1-action2.php template, or if it doesn't exist - just emails.php.  
    1632 
    1733== Changelog == 
     
    1935= 0.1 = 
    2036Basic functionalities added. 
     37 
     38= 0.2 =  
     39* Refactored template hierarchy 
     40* Added output sanitization 
     41* Removed output buffering  
     42* Added a general layout to avoid code duplication 
     43* Theme CSS improvements 
     44* Adjusted wp_mail wrapper to exactly fit the argument structure 
     45* Improved documentation 
     46 
     47== Upgrade Notice == 
     48= 0.2 = 
     49The 0.2 version can be used not only in development, but also on live sites. All major bugs fixed. 
  • enhanced-emails/trunk/templates/action_links.php

    r413849 r422932  
    1 <table> 
    2     <tr><td style="line-height:200%;"><?php eemails_action_links( $action_links, $action_links_label ); ?></td></tr> 
    3 </table> 
     1<?php 
     2$html_email .= '<table> 
     3    <tr><td style="line-height:200%;">' . eemails_get_action_links( $action_links, $action_links_label ) . '</td></tr> 
     4</table>'; 
     5?> 
    46 
  • enhanced-emails/trunk/templates/email-comment-notify.php

    r413849 r422932  
    1 <!DOCTYPE html> 
    2 <html> 
    3 <head> 
    4     <title></title> 
    5     <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> 
    6 </head> 
    7  
    8 <body> 
    9     <div style="width:650px;margin:0 30px 15px 30px;color:#000000;font-family:Arial;font-size:12px;"> 
    10         <a href="#" style="border:0;"><img src="<?php echo eemails_get_logo_url(); ?>" alt="WordPress" style="margin:15px;" /></a> 
    11         <div style="padding: 30px; margin: 0; background-color: #f5f5f5; border: 1px solid #ececec; -webkit-border-radius: 5px; -moz-border-radius: 5px; border-radius: 5px;"> 
    12             <?php if ( $include_header ) include( 'header.php' ); ?> 
    13             <?php if ( 'comment' == $comment_type ) { ?> 
    14             <table style="margin-top:15px;"> 
     1<?php  
     2            if ( 'comment' == $comment_type ) {  
     3            $html_email .= '<table style="margin-top:1em;"> 
    154                <tr> 
    165                    <td style="width:75px;" width="75" rowspan="3"> 
    176                    <div style="width:60px;height:60px;background-color: #ffffff; border: 1px solid #ececec; -webkit-border-radius: 5px; -moz-border-radius: 5px; border-radius: 5px;"> 
    18                         <a style="margin:5px 0 0 5px;display:block;"><?php echo eemails_get_gravatar($comment->comment_author_email); ?></a> 
     7                        <a style="margin:5px 0 0 5px;display:block;">' . eemails_get_gravatar($comment->comment_author_email) . '</a> 
    198                    </div></td> 
    20                     <td height="12" style="height:12px;padding-top:2px;">Author: <strong><?php echo $comment->comment_author; ?></strong></td> 
     9                    <td height="12" style="height:12px;padding-top:2px;">Author: <strong>' . $comment->comment_author . '</strong></td> 
    2110                </tr> 
    22                 <tr><td style="font-size:10px;padding-left:45px;vertical-align:top">IP: <?php echo $comment->comment_author_IP; ?><?php if ( $comment->comment_author_domain ) { ?>, <a href="#" style="color:#21759b;text-decoration:none;"><?php echo $comment->comment_author_domain; ?></a><?php } ?></td></tr> 
    23                 <tr><td>Email: <a href="mailto:<?php echo $comment->comment_author_email; ?>" style="color:#21759b;text-decoration:none;"><?php echo $comment->comment_author_email; ?></a></td></tr> 
     11                <tr><td style="font-size:10px;padding-left:45px;vertical-align:top">IP: ' . $comment->comment_author_IP;  
     12            if ( $comment->comment_author_domain ) { $html_email .= ', <a href="#" style="color:#21759b;text-decoration:none;">' . $comment->comment_author_domain . '</a>'; }  
     13            $html_email .= '</td></tr> 
     14                <tr><td>Email: <a href="mailto:' . $comment->comment_author_email . '" style="color:#21759b;text-decoration:none;">' . $comment->comment_author_email . '</a></td></tr> 
    2415            </table> 
    2516            <table style="margin-top:15px;"> 
    26                 <tr><td style="line-height:150%;">URL: <a href="<?php echo $comment->comment_author_url; ?>" style="color:#21759b;text-decoration:none;"><?php echo $comment->comment_author_url; ?></a></td></tr> 
    27                 <tr><td style="line-height:150%;">Whois: <a href="http://whois.arin.net/rest/ip/<?php echo $comment->comment_author_IP; ?>" style="color:#21759b;text-decoration:none;">http://whois.arin.net/rest/ip/<?php echo $comment->comment_author_IP; ?></a></td></tr> 
    28             </table> 
    29             <?php } elseif ( 'trackback' == $comment_type ) { ?> 
    30             <table style="margin-top:15px;"> 
    31                 <tr><td>Website: <a href="#" style="color:#21759b;text-decoration:none;"><?php echo $comment->comment_author; ?></a></td></tr> 
    32                 <tr><td style="font-size:10px;padding-left:45px;vertical-align:top">IP: <?php echo $comment->comment_author_IP; ?><?php if ( $comment->comment_author_domain ) { ?>, <a href="#" style="color:#21759b;text-decoration:none;"><?php echo $comment->comment_author_domain; ?></a><?php } ?></td></tr> 
     17                <tr><td style="line-height:150%;">URL: <a href="' . $comment->comment_author_url . '" style="color:#21759b;text-decoration:none;">' . $comment->comment_author_url . '</a></td></tr> 
     18                <tr><td style="line-height:150%;">Whois: <a href="http://whois.arin.net/rest/ip/' . $comment->comment_author_IP . '" style="color:#21759b;text-decoration:none;">http://whois.arin.net/rest/ip/' . $comment->comment_author_IP . '</a></td></tr> 
     19            </table>'; 
     20            } elseif ( 'trackback' == $comment_type ) {  
     21            $html_email .= '<table style="margin-top:15px;"> 
     22                <tr><td>Website: <a href="' . $comment->comment_author . '" style="color:#21759b;text-decoration:none;">' . $comment->comment_author . '</a></td></tr> 
     23                <tr><td style="font-size:10px;padding-left:45px;vertical-align:top">IP: ' . $comment->comment_author_IP;  
     24            if ( $comment->comment_author_domain ) { $html_email .= ', <a href="' . $comment->comment_author_domain . '" style="color:#21759b;text-decoration:none;">' . $comment->comment_author_domain . '</a>';} 
     25            $html_email .= '</td></tr> 
    3326            </table> 
    3427            <table style="margin-top:15px;"> 
    35                 <tr><td style="line-height:150%;">URL: <a href="#" style="color:#21759b;text-decoration:none;"><?php echo $comment->comment_author_url; ?></a></td></tr> 
    36             </table> 
    37             <?php } elseif ( 'pingback' == $comment_type ) { ?> 
    38             <table style="margin-top:15px;"> 
    39                 <tr><td>Website: <a href="#" style="color:#21759b;text-decoration:none;"><?php echo $comment->comment_author; ?></a></td></tr> 
    40                 <tr><td style="font-size:10px;padding-left:45px;vertical-align:top">IP: <?php echo $comment->comment_author_IP; ?><?php if ( $comment->comment_author_domain ) { ?>, <a href="#" style="color:#21759b;text-decoration:none;"><?php echo $comment->comment_author_domain; ?></a><?php } ?></td></tr> 
     28                <tr><td style="line-height:150%;">URL: <a href="' . $comment->comment_author_url . '" style="color:#21759b;text-decoration:none;">' . $comment->comment_author_url . '</a></td></tr> 
     29            </table>'; 
     30            } elseif ( 'pingback' == $comment_type ) {  
     31            $html_email .= '<table style="margin-top:15px;"> 
     32                <tr><td>Website: <a href="' . $comment->comment_author . '" style="color:#21759b;text-decoration:none;">' . $comment->comment_author . '</a></td></tr> 
     33                <tr><td style="font-size:10px;padding-left:45px;vertical-align:top">IP: ' . $comment->comment_author_IP; 
     34            if ( $comment->comment_author_domain ) { $html_email .= ', <a href="#" style="color:#21759b;text-decoration:none;">' . $comment->comment_author_domain .'</a><';} 
     35            $html_email .= '</td></tr> 
    4136            </table> 
    4237            <table style="margin-top:15px;"> 
    43                 <tr><td style="line-height:150%;">URL: <a href="#" style="color:#21759b;text-decoration:none;"><?php echo $comment->comment_author_url; ?></a></td></tr> 
    44             </table> 
    45             <?php } ?> 
    46             <div style="line-height:170%;padding: 30px; margin: 15px 0 15px 0;background-color: #ffffff; border: 1px solid #ececec; -webkit-border-radius: 5px; -moz-border-radius: 5px; border-radius: 5px;"> 
    47                 <?php  
    48                 if ( 'pingback' == $comment_type ) echo '[...] '; 
    49                 echo $comment->comment_content; 
    50                 if ( 'pingback' == $comment_type ) echo ' [...]'; 
    51                 ?> 
    52             </div> 
     38                <tr><td style="line-height:150%;">URL: <a href="' . $comment->comment_author_url . '" style="color:#21759b;text-decoration:none;">' . $comment->comment_author_url . '</a></td></tr> 
     39            </table>'; 
     40            }  
     41            $html_email .= '<div style="line-height:170%;padding: 2em; margin: 1em 0 1em 0;background-color: #ffffff; border: 1px solid #ececec; -webkit-border-radius: 5px; -moz-border-radius: 5px; border-radius: 5px;" id="EemailsContent">'; 
     42            if ( 'pingback' == $comment_type ) $html_email .= '[...] '; 
     43            $html_email .= wp_specialchars_decode( $comment->comment_content ); 
     44            if ( 'pingback' == $comment_type ) $html_email .= ' [...]'; 
     45           $html_email .= ' </div> 
    5346            <table> 
    54                 <tr><td style="line-height:150%;">Context: <a href="#" style="color:#21759b;text-decoration:none;"><?php echo get_permalink( $comment->comment_post_ID ); ?></a></td></tr> 
    55                 <!-- Take action: <a href="#" style="color:#3ca757;text-decoration:none;margin: 0 10px;font-weight:bold; font-size: 14px">Approve</a> | <a href="#" style="color:#d2b12e;text-decoration:none;margin: 0 10px;font-weight:bold; font-size: 14px">Mark as spam</a> | <a href="#" style="color:#c23031;text-decoration:none;margin: 0 10px;font-weight:bold; font-size: 14px">Trash</a> --> 
    56                 <tr><td style="line-height:200%;"><?php eemails_action_links( $action_links, $action_label ); ?></td></tr> 
    57                 <?php if ( isset( $moderation_message ) ) { ?> 
    58                 <tr><td style="line-height:150%;"><?php echo $moderation_message; ?></td></tr> 
    59                 <?php } ?> 
    60             </table> 
    61             <?php if ( $include_footer ) include( 'footer.php' ); ?> 
    62         </div> 
    63     </div> 
    64     </body> 
    65 </html> 
     47                <tr><td style="line-height:150%;">Context: <a href="' . get_permalink( $comment->comment_post_ID ) . '" style="color:#21759b;text-decoration:none;">' . get_permalink( $comment->comment_post_ID ) . '</a></td></tr>'; 
     48           if ( isset( $moderation_message ) ) { 
     49                $html_email .= ' <tr><td style="line-height:150%;">' . $moderation_message . '</td></tr>'; 
     50            } 
     51            $html_email .= ' </table>'; 
     52            if ( ! empty( $action_links ) ) include( 'action_links.php' ); 
     53?> 
  • enhanced-emails/trunk/templates/email-newblog.php

    r413849 r422932  
    1 <!DOCTYPE html> 
    2 <html> 
    3 <head> 
    4     <title></title> 
    5     <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> 
    6 </head> 
    7  
    8 <body> 
    9     <div style="width:650px;margin:0 30px 15px 30px;color:#000000;font-family:Arial;font-size:12px;"> 
    10         <a href="#" style="border:0;"><img src="<?php echo eemails_get_logo_url(); ?>" alt="WordPress" style="margin:15px;" /></a> 
    11         <div style="padding: 30px; margin: 0; background-color: #f5f5f5; border: 1px solid #ececec; -webkit-border-radius: 5px; -moz-border-radius: 5px; border-radius: 5px;"> 
    12             <?php if ( $include_header ) include( 'header.php' ); ?> 
    13             <div style="line-height:170%;padding: 30px; margin: 15px 0 15px 0;background-color: #ffffff; border: 1px solid #ececec; -webkit-border-radius: 5px; -moz-border-radius: 5px; border-radius: 5px;"> 
     1<?php 
     2            $html_email .= '<div style="line-height:170%;padding: 2em; margin: 1em 0 1em 0;background-color: #ffffff; border: 1px solid #ececec; -webkit-border-radius: 5px; -moz-border-radius: 5px; border-radius: 5px;" id="EemailsContent"> 
    143                Your new WordPress blog has been successfully set up at:<br /> 
    15                 <a href="#" style="color:#21759b;text-decoration:none;">http://wojtekszkutnik.com</a> 
    16                 <p style="margin:30px 0 0 0">You can log in to the administrator account with the following information:<br /> 
     4                <a href="' . site_url() . '" style="color:#21759b;text-decoration:none;">' . site_url() . '</a> 
     5                <p style="margin:2em 0 0 0">You can log in to the administrator account with the following information:<br /> 
    176                Username: <strong>admin</strong><br /> 
    187                Password: the password you chose during the install</p> 
    19             </div> 
    20             <?php if ( ! empty( $action_links ) ) include( 'action_links.php' ); ?> 
    21             <?php if ( $include_footer ) include( 'footer.php' ); ?> 
    22         </div> 
    23     </div> 
    24     </body> 
    25 </html> 
     8            </div>'; 
     9            if ( ! empty( $action_links ) ) include( 'action_links.php' );  
     10            $html_email .= '<p style="margin-top:15px;line-height:170%;">We hope you enjoy your new blog. Thanks! <br />'; 
     11?> 
  • enhanced-emails/trunk/templates/email-newuser-admin.php

    r413849 r422932  
    1 <!DOCTYPE html> 
    2 <html> 
    3 <head> 
    4     <title></title> 
    5     <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> 
    6 </head> 
    7  
    8 <body> 
    9     <div style="width:650px;margin:0 30px 15px 30px;color:#000000;font-family:Arial;font-size:12px;"> 
    10         <a href="#" style="border:0;"><img src="<?php echo eemails_get_logo_url(); ?>" alt="WordPress" style="margin:15px;" /></a> 
    11         <div style="padding: 30px; margin: 0; background-color: #f5f5f5; border: 1px solid #ececec; -webkit-border-radius: 5px; -moz-border-radius: 5px; border-radius: 5px;"> 
    12             <?php if ( $include_header ) include( 'header.php' ); ?> 
    13  
    14             <div style="line-height:170%;padding: 30px; margin: 15px 0 15px 0;background-color: #ffffff; border: 1px solid #ececec; -webkit-border-radius: 5px; -moz-border-radius: 5px; border-radius: 5px;"> 
    15                 <p style="margin:30px 0 10 0">A new user - <strong><?php echo $user->display_name; ?></strong>, has just registered on your site.</p> 
    16                 <p style="margin:30px 0 10 0"> 
    17                 Username: <strong><?php echo $user->user_login; ?></strong><br /> 
    18                 Email: <strong style="text-decoration:none !important;"><?php echo $user->user_email; ?></strong><br /></p> 
    19             </div> 
    20             <?php if ( ! empty( $action_links ) ) include( 'action_links.php' ); ?> 
    21             <?php if ( $include_footer ) include( 'footer.php' ); ?> 
    22         </div> 
    23     </div> 
    24     </body> 
    25 </html> 
     1<?php 
     2            $html_email .= '<div style="line-height:170%;padding: 2em; margin: 1em 0 1em 0;background-color: #ffffff; border: 1px solid #ececec; -webkit-border-radius: 5px; -moz-border-radius: 5px; border-radius: 5px;" id="EemailsContent"> 
     3                <p style="margin:2em 0 0.8em 0">A new user - <strong>' . $user->display_name . '</strong>, has just registered on your site.</p> 
     4                <p style="margin:2em 0 0.8em 0"> 
     5                Username: <strong>' . $user->user_login . '</strong><br /> 
     6                Email: <strong style="text-decoration:none !important;">' . $user->user_email . '</strong><br /></p> 
     7            </div>'; 
     8            if ( ! empty( $action_links ) ) include( 'action_links.php' ); 
     9?> 
  • enhanced-emails/trunk/templates/email-newuser-user.php

    r413849 r422932  
    1 <!DOCTYPE html> 
    2 <html> 
    3 <head> 
    4     <title></title> 
    5     <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> 
    6 </head> 
    7  
    8 <body> 
    9     <div style="width:650px;margin:0 30px 15px 30px;color:#000000;font-family:Arial;font-size:12px;"> 
    10         <a href="#" style="border:0;"><img src="<?php echo eemails_get_logo_url(); ?>" alt="WordPress" style="margin:15px;" /></a> 
    11         <div style="padding: 30px; margin: 0; background-color: #f5f5f5; border: 1px solid #ececec; -webkit-border-radius: 5px; -moz-border-radius: 5px; border-radius: 5px;"> 
    12             <?php if ( $include_header ) include( 'header.php' ); ?> 
    13             <div style="line-height:170%;padding: 30px; margin: 15px 0 15px 0;background-color: #ffffff; border: 1px solid #ececec; -webkit-border-radius: 5px; -moz-border-radius: 5px; border-radius: 5px;"> 
    14                 Howdy, Wojtek! 
    15                 <p style="margin:30px 0 10 0">Your account has been successfully created and is ready to use!<!--<br /> 
    16                 <a href="#" style="color:#21759b;text-decoration:none;"></a>--></p> 
     1<?php 
     2            $html_email .= '<div style="line-height:170%;padding: 2em; margin: 1em 0 1em 0;background-color: #ffffff; border: 1px solid #ececec; -webkit-border-radius: 5px; -moz-border-radius: 5px; border-radius: 5px;" id="EemailsContent"> 
     3                Howdy, ' . $user->user_login . '! 
     4                <p style="margin:30px 0 10 0">Your account has been successfully created and is ready to use!</p> 
    175                <p style="margin:30px 0 10 0">You can log in to your account with the following information:<br /> 
    18                 Username: <strong><?php echo $user->user_login; ?></strong><br /> 
    19                 Password: <strong><?php echo $user_password; ?></strong><br /></p> 
    20             </div> 
    21             <?php if ( ! empty( $action_links ) ) include( 'action_links.php' ); ?> 
    22             <?php if ( $include_footer ) include( 'footer.php' ); ?> 
    23         </div> 
    24     </div> 
    25     </body> 
    26 </html> 
     6                Username: <strong>' . $user->user_login . '</strong><br /> 
     7                Password: <strong>' . $user_password . '</strong><br /></p> 
     8            </div>'; 
     9            if ( ! empty( $action_links ) ) include( 'action_links.php' ); 
     10?> 
  • enhanced-emails/trunk/templates/email-passwordchange-admin.php

    r413849 r422932  
    1 <!DOCTYPE html> 
    2 <html> 
    3 <head> 
    4     <title></title> 
    5     <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> 
    6 </head> 
    7  
    8 <body> 
    9     <div style="width:650px;margin:0 30px 15px 30px;color:#000000;font-family:Arial;font-size:12px;"> 
    10         <a href="#" style="border:0;"><img src="<?php echo eemails_get_logo_url(); ?>" alt="WordPress" style="margin:15px;" /></a> 
    11         <div style="padding: 30px; margin: 0; background-color: #f5f5f5; border: 1px solid #ececec; -webkit-border-radius: 5px; -moz-border-radius: 5px; border-radius: 5px;"> 
    12             <?php if( $include_header ) include( 'header.php' ); ?> 
    13             <div style="line-height:170%;padding: 30px; margin: 15px 0 15px 0;background-color: #ffffff; border: 1px solid #ececec; -webkit-border-radius: 5px; -moz-border-radius: 5px; border-radius: 5px;"> 
    14                 <p style="margin:30px 0 10 0">The password was reset and changed for the following user:</p> 
    15                 <p style="margin:30px 0 10 0"> 
    16                 Username: <strong><?php echo $user->user_login; ?></strong><br /> 
    17                 Email: <strong><?php echo $user->user_email; ?></strong><br /></p> 
    18             </div> 
    19             <?php if ( ! empty( $action_links ) ) include( 'action_links.php' ); ?> 
    20             <?php if ( $include_footer ) include( 'footer.php' ); ?> 
    21         </div> 
    22     </div> 
    23     </body> 
    24 </html> 
     1<?php 
     2            $html_email .= '<div style="line-height:170%;padding: 30px; margin: 15px 0 15px 0;background-color: #ffffff; border: 1px solid #ececec; -webkit-border-radius: 5px; -moz-border-radius: 5px; border-radius: 5px;" id="EemailsContent"> 
     3                <p style="margin:2em 0 0.8em 0">The password was reset and changed for the following user:</p> 
     4                <p style="margin:2em 0 0.8em 0"> 
     5                Username: <strong>' . $user->user_login . '</strong><br /> 
     6                Email: <strong>' . $user->user_email . '</strong><br /></p> 
     7            </div>'; 
     8            if ( ! empty( $action_links ) ) include( 'action_links.php' ); 
     9?> 
  • enhanced-emails/trunk/templates/email.php

    r413849 r422932  
    1 <!DOCTYPE html> 
    2 <html> 
    3 <head> 
    4     <title></title> 
    5     <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> 
    6 </head> 
    7  
    8 <body> 
    9     <div style="width:650px;margin:0 30px 15px 30px;color:#000000;font-family:Arial;font-size:12px;"> 
    10         <a href="#" style="border:0;"><img src="<?php echo eemails_get_logo_url(); ?>" alt="WordPress" style="margin:15px;" /></a> 
    11         <div style="padding: 30px; margin: 0; background-color: #f5f5f5; border: 1px solid #ececec; -webkit-border-radius: 5px; -moz-border-radius: 5px; border-radius: 5px;"> 
    12         <?php if ( $include_header ) include( 'header.php' ); ?> 
    13             <div style="line-height:170%;padding: 30px; margin: 15px 0 15px 0;background-color: #ffffff; border: 1px solid #ececec; -webkit-border-radius: 5px; -moz-border-radius: 5px; border-radius: 5px;"> 
    14                 <?php echo $message; ?> 
    15             </div> 
    16         <?php if ( ! empty( $action_links ) ) include( 'action_links.php' ); ?> 
    17         <?php if ( $include_footer ) include( 'footer.php' ); ?> 
    18         </div> 
    19     </div> 
    20     </body> 
    21 </html> 
     1<?php $html_email .= wp_specialchars_decode( $message ); ?> 
  • enhanced-emails/trunk/templates/footer.php

    r413849 r422932  
    1 <p style="margin-top:15px;line-height:170%;">We hope you enjoy your new blog. Thanks! <br /> 
     1<?php 
     2$html_email .= ' 
    23-- The WordPress Team <br /> 
    3 <a href="#" style="color:#21759b;text-decoration:none;">http://wordpress.org</a> 
     4<a href="http://wordpress.org" style="color:#21759b;text-decoration:none;">http://wordpress.org</a>'; 
     5?> 
  • enhanced-emails/trunk/templates/header.php

    r413849 r422932  
    1 <h1 style="margin:0;padding:0;color:#21759b;font-size:20px;font-weight:bold;font-family:Arial;line-height:22px;"> 
    2     <?php echo $content_title; ?> 
    3 </h1> 
     1<?php 
     2$html_email .= '<h1 style="margin:0;padding:0;color:#21759b;font-size:20px;font-weight:bold;font-family:Arial;line-height:22px;"> 
     3    ' . $content_title . ' 
     4</h1>'; 
     5?> 
Note: See TracChangeset for help on using the changeset viewer.