Version Description
- Fixed live preview feature
Download this release
Release Info
Developer | nlemoine |
Plugin | WP Better Emails |
Version | 0.2.6.4 |
Comparing to | |
See all releases |
Code changes from version 0.2.6.3 to 0.2.6.4
- js/wpbe-admin-script.js +26 -16
- readme.txt +10 -2
- wpbe-options.php +1 -1
- wpbe.php +1 -10
js/wpbe-admin-script.js
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
jQuery(document).ready(function($){
|
2 |
|
3 |
// Send email preview
|
4 |
-
$('#wpbe_send_preview').click
|
5 |
e.preventDefault();
|
6 |
var email = $('#wpbe_email_preview_field').val(), message = $('#wpbe_preview_message'), loading = $('#wpbe_ajax_loading');
|
7 |
$.ajax({
|
@@ -25,28 +25,38 @@ jQuery(document).ready(function($){
|
|
25 |
});
|
26 |
|
27 |
// Trigger help
|
28 |
-
$('.wpbe_help').
|
29 |
e.preventDefault();
|
30 |
$('a#contextual-help-link').trigger('click');
|
31 |
});
|
32 |
|
33 |
// Thickbox preview
|
34 |
-
$('#wpbe_preview_template').
|
35 |
e.preventDefault();
|
36 |
-
|
37 |
-
|
38 |
-
|
39 |
-
|
40 |
-
|
41 |
-
|
42 |
-
|
43 |
-
|
44 |
-
|
45 |
-
|
46 |
-
|
47 |
-
|
48 |
-
|
|
|
|
|
|
|
|
|
|
|
49 |
}
|
|
|
|
|
|
|
|
|
|
|
50 |
});
|
51 |
|
52 |
});
|
1 |
jQuery(document).ready(function($){
|
2 |
|
3 |
// Send email preview
|
4 |
+
$('#wpbe_send_preview').on('click', this, function(e) {
|
5 |
e.preventDefault();
|
6 |
var email = $('#wpbe_email_preview_field').val(), message = $('#wpbe_preview_message'), loading = $('#wpbe_ajax_loading');
|
7 |
$.ajax({
|
25 |
});
|
26 |
|
27 |
// Trigger help
|
28 |
+
$('.wpbe_help').on('click', this, function(e){
|
29 |
e.preventDefault();
|
30 |
$('a#contextual-help-link').trigger('click');
|
31 |
});
|
32 |
|
33 |
// Thickbox preview
|
34 |
+
$('#wpbe_preview_template').on('click', this, function(e) {
|
35 |
e.preventDefault();
|
36 |
+
|
37 |
+
var $this = $(this),
|
38 |
+
title = $this.attr('title'),
|
39 |
+
href = $this.attr('href');
|
40 |
+
|
41 |
+
// Open TB
|
42 |
+
tb_show(title, href);
|
43 |
+
var $previewIframe = $('#TB_iframeContent');
|
44 |
+
|
45 |
+
if( !$previewIframe.length )
|
46 |
+
return;
|
47 |
+
|
48 |
+
var template;
|
49 |
+
if (typeof(tinyMCE) != 'undefined') {
|
50 |
+
if( tinyMCE.activeEditor && !tinyMCE.activeEditor.isHidden() )
|
51 |
+
template = tinyMCE.activeEditor.getContent();
|
52 |
+
else
|
53 |
+
template = $('.wpbe_template').val();
|
54 |
}
|
55 |
+
|
56 |
+
$previewIframe = $previewIframe[$previewIframe.length - 1].contentWindow || frame[$previewIframe.length - 1];
|
57 |
+
$previewIframe.document.open();
|
58 |
+
$previewIframe.document.write( template );
|
59 |
+
$previewIframe.document.close();
|
60 |
});
|
61 |
|
62 |
});
|
readme.txt
CHANGED
@@ -2,8 +2,8 @@
|
|
2 |
Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=7Q49VJQNRCQ8E&lc=FR&item_name=ArtyShow&item_number=wp%2dbetter%2demails¤cy_code=EUR&bn=PP%2dDonationsBF%3abtn_donateCC_LG%2egif%3aNonHosted
|
3 |
Tags: email, emails, html emails, templates, notification, wp_mail, wpmu, multisite
|
4 |
Requires at least: 2.8
|
5 |
-
Tested up to: 3.
|
6 |
-
Stable tag: 0.2.6.
|
7 |
|
8 |
Adds a customizable good looking HTML template to all WP default plain/text emails and lets you set
|
9 |
a custom sender name and email address.
|
@@ -53,6 +53,10 @@ WP Better Emails is currently available in :
|
|
53 |
I'm looking for translators to extend to other languages. If you have translated the plugin in your language or want to,
|
54 |
please let me know : wpbetteremails [ at ] iamnico.la
|
55 |
|
|
|
|
|
|
|
|
|
56 |
= Credits =
|
57 |
|
58 |
[CodeMirror](http://codemirror.net/ "CodeMirror") library
|
@@ -125,6 +129,10 @@ You can place this function in your functions.php theme file or in a plugin.
|
|
125 |
|
126 |
== Changelog ==
|
127 |
|
|
|
|
|
|
|
|
|
128 |
= 0.2.6.3 =
|
129 |
|
130 |
* New translation : Spanish
|
2 |
Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=7Q49VJQNRCQ8E&lc=FR&item_name=ArtyShow&item_number=wp%2dbetter%2demails¤cy_code=EUR&bn=PP%2dDonationsBF%3abtn_donateCC_LG%2egif%3aNonHosted
|
3 |
Tags: email, emails, html emails, templates, notification, wp_mail, wpmu, multisite
|
4 |
Requires at least: 2.8
|
5 |
+
Tested up to: 3.7
|
6 |
+
Stable tag: 0.2.6.4
|
7 |
|
8 |
Adds a customizable good looking HTML template to all WP default plain/text emails and lets you set
|
9 |
a custom sender name and email address.
|
53 |
I'm looking for translators to extend to other languages. If you have translated the plugin in your language or want to,
|
54 |
please let me know : wpbetteremails [ at ] iamnico.la
|
55 |
|
56 |
+
= Contributing =
|
57 |
+
|
58 |
+
WP Better Emails is also available on [GitHub](https://github.com/nlemoine/WP-Better-Emails).
|
59 |
+
|
60 |
= Credits =
|
61 |
|
62 |
[CodeMirror](http://codemirror.net/ "CodeMirror") library
|
129 |
|
130 |
== Changelog ==
|
131 |
|
132 |
+
= 0.2.6.4 =
|
133 |
+
|
134 |
+
* Fixed live preview feature
|
135 |
+
|
136 |
= 0.2.6.3 =
|
137 |
|
138 |
* New translation : Spanish
|
wpbe-options.php
CHANGED
@@ -21,7 +21,7 @@
|
|
21 |
<!-- Template -->
|
22 |
<h3 class="wpbe_title"><?php _e('HTML Template', 'wp-better-emails'); ?>
|
23 |
<?php if( version_compare($wp_version, '3.1', '>') ): ?>
|
24 |
-
<a class="
|
25 |
<?php endif; ?>
|
26 |
</h3>
|
27 |
<p><?php _e('Edit the HTML template if you want to customize it. You might have a look at the <a href="#" class="wpbe_help">help tab</a> for further information.', 'wp-better-emails'); ?></p>
|
21 |
<!-- Template -->
|
22 |
<h3 class="wpbe_title"><?php _e('HTML Template', 'wp-better-emails'); ?>
|
23 |
<?php if( version_compare($wp_version, '3.1', '>') ): ?>
|
24 |
+
<a class="button" title="<?php esc_attr_e('Live template preview', 'wp-better-emails'); ?>" id="wpbe_preview_template" href="<?php echo plugins_url('preview.html?keepThis=true&TB_iframe=true&height=400&width=700', __FILE__); ?>"><?php _e('Live preview', 'wp-better-emails'); ?></a>
|
25 |
<?php endif; ?>
|
26 |
</h3>
|
27 |
<p><?php _e('Edit the HTML template if you want to customize it. You might have a look at the <a href="#" class="wpbe_help">help tab</a> for further information.', 'wp-better-emails'); ?></p>
|
wpbe.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
Plugin Name: WP Better Emails
|
4 |
Plugin URI: http://wordpress.org/extend/plugins/wp-better-emails/
|
5 |
Description: Beautify the default text/plain WP mails into fully customizable HTML emails.
|
6 |
-
Version: 0.2.6.
|
7 |
Author: ArtyShow
|
8 |
Author URI: http://wordpress.org/extend/plugins/wp-better-emails/
|
9 |
License: GPLv2
|
@@ -41,15 +41,6 @@ if ( ! class_exists( 'WP_Better_Emails' ) ) {
|
|
41 |
var $page = '';
|
42 |
var $send_as_html;
|
43 |
|
44 |
-
/**
|
45 |
-
* Construct function (old way)
|
46 |
-
*
|
47 |
-
* @since 0.2
|
48 |
-
*/
|
49 |
-
function WP_Better_Emails() {
|
50 |
-
$this->__construct();
|
51 |
-
}
|
52 |
-
|
53 |
/**
|
54 |
* Construct function
|
55 |
*
|
3 |
Plugin Name: WP Better Emails
|
4 |
Plugin URI: http://wordpress.org/extend/plugins/wp-better-emails/
|
5 |
Description: Beautify the default text/plain WP mails into fully customizable HTML emails.
|
6 |
+
Version: 0.2.6.4
|
7 |
Author: ArtyShow
|
8 |
Author URI: http://wordpress.org/extend/plugins/wp-better-emails/
|
9 |
License: GPLv2
|
41 |
var $page = '';
|
42 |
var $send_as_html;
|
43 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
44 |
/**
|
45 |
* Construct function
|
46 |
*
|