wpMandrill - Version 1.27

Version Description

  • FIXED: Removing php short tags. ** Thanks Kailey Lampert! **
Download this release

Release Info

Developer MC_Will
Plugin Icon wp plugin wpMandrill
Version 1.27
Comparing to
See all releases

Code changes from version 1.26 to 1.27

Files changed (3) hide show
  1. readme.txt +3 -0
  2. stats.php +19 -19
  3. wpmandrill.php +7 -7
readme.txt CHANGED
@@ -92,6 +92,9 @@ If your account has more than 20 senders registered or more than 40 tags used, t
92
 
93
  == Changelog ==
94
 
 
 
 
95
  = 1.26 =
96
  * UPDATED: Now Mandrill accepts any content type and so does wpMandrill.
97
  * FIXED: Queued messages were triggering the native wp_mail function. ** Thanks Scott Connerly! **
92
 
93
  == Changelog ==
94
 
95
+ = 1.27 =
96
+ * FIXED: Removing php short tags. ** Thanks Kailey Lampert! **
97
+
98
  = 1.26 =
99
  * UPDATED: Now Mandrill accepts any content type and so does wpMandrill.
100
  * FIXED: Queued messages were triggering the native wp_mail function. ** Thanks Scott Connerly! **
stats.php CHANGED
@@ -38,12 +38,12 @@ $lit['clickrate'] = __('Click Rate','wpmandrill');
38
  <h3><?php echo sprintf(__('All-time statistics since %s: ', 'wpmandrill'),date('m/d/Y',strtotime($stats['general']['created_at']))); ?></h3>
39
 
40
  <div id="alltime_report_canvas">
41
- <div class="stat_box"><?php _e('Reputation:', 'wpmandrill'); ?><br/><span><?=$stats['general']['reputation']?>%</span></div>
42
- <div class="stat_box"><?php _e('Quota:', 'wpmandrill'); ?><br/><span><?=$stats['general']['hourly_quota']?> <?php _e('sends/hour', 'wpmandrill'); ?></span></div>
43
- <div class="stat_box"><?php _e('Emails sent:', 'wpmandrill'); ?><br/><span><?=$stats['general']['stats']['sent']?></span></div>
44
- <div class="stat_box"><?php _e('Emails delivered:', 'wpmandrill'); ?><br/><span><?=$delivered?> (<?=number_format( $delivered*100 / ( ($stats['general']['stats']['sent'])?$stats['general']['stats']['sent']:1 ) ,2); ?>%)</span></div>
45
- <div class="stat_box"><?php _e('Tracked opens:', 'wpmandrill'); ?><br/><span><?=$stats['general']['stats']['opens']?></span></div>
46
- <div class="stat_box"><?php _e('Tracked clicks:', 'wpmandrill'); ?><br/><span><?=$stats['general']['stats']['clicks']?></span></div>
47
  <?php
48
  if ( $stats['general']['stats']['rejects'] ) echo '<div class="stat_box warning">'.__('Rejects:', 'wpmandrill').'<br/><span>'.$stats['general']['stats']['rejects'].'</span></div>';
49
  if ( $stats['general']['stats']['complaints'] ) echo '<div class="stat_box warning">'.__('Complaints:', 'wpmandrill').'<br/><span>'.$stats['general']['stats']['complaints'].'</span></div>';
@@ -142,14 +142,14 @@ function wpm_showTooltip(x, y, contents) {
142
 
143
 
144
  ?>
145
- var hvolume = [<?=implode(',',$hvolume);?>];
146
- var hopenrates = [<?=implode(',',$horate);?>];
147
- var hclickrates = [<?=implode(',',$hcrate);?>]
148
 
149
- var dvolume = [<?=implode(',',$dvolume);?>];
150
- var dopenrates = [<?=implode(',',$dorate);?>];
151
- var dclickrates = [<?=implode(',',$dcrate);?>]
152
- var dticks = [<?=implode(',',array_keys($stats['graph']['daily']['delivered']));?>]
153
  jQuery(function () {
154
  var previousPoint = null;
155
  jQuery("#hourly_report_canvas").bind("plothover", function (event, pos, item) {
@@ -218,7 +218,7 @@ jQuery(function () {
218
  right: 100
219
  }
220
  },
221
- xaxes: [ { ticks: [<?=implode(',',$hticks);?>] } ],
222
  yaxes: [ { min: 0, tickFormatter: percentageFormatter },
223
  {
224
  min: 0,
@@ -250,7 +250,7 @@ jQuery(function () {
250
  right: 10
251
  }
252
  },
253
- xaxes: [ { ticks: [<?=implode(',', $dticks);?>] } ],
254
  yaxes: [ { min: 0, tickFormatter: percentageFormatter },
255
  {
256
  min: 0,
@@ -262,11 +262,11 @@ jQuery(function () {
262
  });
263
  });
264
  </script>
265
- <h3><?=$lit['hourly']['title']; ?></h3>
266
- <h4><?=$lit['subtitle']; ?></h4>
267
  <div id="hourly_report_canvas" style="height: 400px;"></div><br/><br/>
268
- <h3><?=$lit['daily']['title']; ?></h3>
269
- <h4><?=$lit['subtitle']; ?></h4>
270
  <div id="daily_report_canvas" style="height: 400px;"></div>
271
  <h3><a href="http://mandrillapp.com/" target="_target"><?php _e('For more detailed statistics, please visit your Mandrill Dashboard','wpmandrill'); ?></a>.</h3>
272
 
38
  <h3><?php echo sprintf(__('All-time statistics since %s: ', 'wpmandrill'),date('m/d/Y',strtotime($stats['general']['created_at']))); ?></h3>
39
 
40
  <div id="alltime_report_canvas">
41
+ <div class="stat_box"><?php _e('Reputation:', 'wpmandrill'); ?><br/><span><?php echo $stats['general']['reputation']?>%</span></div>
42
+ <div class="stat_box"><?php _e('Quota:', 'wpmandrill'); ?><br/><span><?php echo $stats['general']['hourly_quota']?> <?php _e('sends/hour', 'wpmandrill'); ?></span></div>
43
+ <div class="stat_box"><?php _e('Emails sent:', 'wpmandrill'); ?><br/><span><?php echo $stats['general']['stats']['sent']?></span></div>
44
+ <div class="stat_box"><?php _e('Emails delivered:', 'wpmandrill'); ?><br/><span><?php echo $delivered?> (<?php echo number_format( $delivered*100 / ( ($stats['general']['stats']['sent'])?$stats['general']['stats']['sent']:1 ) ,2); ?>%)</span></div>
45
+ <div class="stat_box"><?php _e('Tracked opens:', 'wpmandrill'); ?><br/><span><?php echo $stats['general']['stats']['opens']?></span></div>
46
+ <div class="stat_box"><?php _e('Tracked clicks:', 'wpmandrill'); ?><br/><span><?php echo $stats['general']['stats']['clicks']?></span></div>
47
  <?php
48
  if ( $stats['general']['stats']['rejects'] ) echo '<div class="stat_box warning">'.__('Rejects:', 'wpmandrill').'<br/><span>'.$stats['general']['stats']['rejects'].'</span></div>';
49
  if ( $stats['general']['stats']['complaints'] ) echo '<div class="stat_box warning">'.__('Complaints:', 'wpmandrill').'<br/><span>'.$stats['general']['stats']['complaints'].'</span></div>';
142
 
143
 
144
  ?>
145
+ var hvolume = [<?php echo implode(',',$hvolume);?>];
146
+ var hopenrates = [<?php echo implode(',',$horate);?>];
147
+ var hclickrates = [<?php echo implode(',',$hcrate);?>]
148
 
149
+ var dvolume = [<?php echo implode(',',$dvolume);?>];
150
+ var dopenrates = [<?php echo implode(',',$dorate);?>];
151
+ var dclickrates = [<?php echo implode(',',$dcrate);?>]
152
+ var dticks = [<?php echo implode(',',array_keys($stats['graph']['daily']['delivered']));?>]
153
  jQuery(function () {
154
  var previousPoint = null;
155
  jQuery("#hourly_report_canvas").bind("plothover", function (event, pos, item) {
218
  right: 100
219
  }
220
  },
221
+ xaxes: [ { ticks: [<?php echo implode(',',$hticks);?>] } ],
222
  yaxes: [ { min: 0, tickFormatter: percentageFormatter },
223
  {
224
  min: 0,
250
  right: 10
251
  }
252
  },
253
+ xaxes: [ { ticks: [<?php echo implode(',', $dticks);?>] } ],
254
  yaxes: [ { min: 0, tickFormatter: percentageFormatter },
255
  {
256
  min: 0,
262
  });
263
  });
264
  </script>
265
+ <h3><?php echo $lit['hourly']['title']; ?></h3>
266
+ <h4><?php echo $lit['subtitle']; ?></h4>
267
  <div id="hourly_report_canvas" style="height: 400px;"></div><br/><br/>
268
+ <h3><?php echo $lit['daily']['title']; ?></h3>
269
+ <h4><?php echo $lit['subtitle']; ?></h4>
270
  <div id="daily_report_canvas" style="height: 400px;"></div>
271
  <h3><a href="http://mandrillapp.com/" target="_target"><?php _e('For more detailed statistics, please visit your Mandrill Dashboard','wpmandrill'); ?></a>.</h3>
272
 
wpmandrill.php CHANGED
@@ -5,7 +5,7 @@ Description: wpMandrill sends emails, generated by WordPress using Mandrill.
5
  Author: Mandrill
6
  Author URI: http://mandrillapp.com/
7
  Plugin URI: http://connect.mailchimp.com/integrations/wpmandrill
8
- Version: 1.26
9
  Text Domain: wpmandrill
10
  */
11
  /* Copyright 2012 MailChimp (email : will@mailchimp.com )
@@ -284,7 +284,7 @@ class wpMandrill {
284
  ?>
285
  <div class="wrap">
286
  <div class="icon32" style="background: url('<?php echo plugins_url('images/mandrill-head-icon.png',__FILE__); ?>');"><br /></div>
287
- <h2><?php _e('Mandrill Settings', 'wpmandrill'); ?> <small><a href="options-general.php?page=<?='wpmandrill'; ?>&show=how-tos">view how-tos</a></small></h2>
288
 
289
  <div style="float: left;width: 70%;">
290
  <form method="post" action="options.php">
@@ -366,7 +366,7 @@ class wpMandrill {
366
  ?>
367
  <div class="wrap">
368
  <div class="icon32" style="background: url('<?php echo plugins_url('images/mandrill-head-icon.png',__FILE__); ?>');"><br /></div>
369
- <h2><?php _e('Mandrill How-Tos', 'wpmandrill'); ?> <small><a href="options-general.php?page=<?='wpmandrill'; ?>">back to settings</a></small></h2>
370
  <?php
371
  require plugin_dir_path( __FILE__ ) . '/how-tos.php';
372
 
@@ -821,7 +821,7 @@ jQuery(document).bind( 'ready', function() {
821
  ?>
822
  <div class="inside">
823
  <?php _e('Replace all line feeds ("\n") by &lt;br/&gt; in the message body?', 'wpmandrill'); ?>
824
- <input name="wpmandrill[nl2br]" type="checkbox" <?=checked($nl2br,1); ?> value='1' /><br/>
825
  <span class="setting-description"><em><?php _e('<small>If you are sending HTML emails already keep this setting deactivated.<br/>But if you are sending text only emails (WordPress default) this option might help your emails look better.</small>', 'wpmandrill'); ?></em></span>
826
  </div><?php
827
  }
@@ -1345,7 +1345,7 @@ JS;
1345
  ?>
1346
  <label for="filter"><?php _e('Filter by:', 'wpmandrill'); ?> </label>
1347
  <select id="filter" name="filter">
1348
- <option value="none" <?=selected($filter, 'none');?>><?php _e('No filter', 'wpmandrill'); ?></option>
1349
  <optgroup label="<?php _e('Sender:', 'wpmandrill'); ?>">
1350
  <?php
1351
  foreach ( array_keys($stats['stats']['hourly']['senders']) as $sender) {
@@ -1363,8 +1363,8 @@ JS;
1363
  </select>
1364
  <label for="display"><?php _e('Display:', 'wpmandrill'); ?> </label>
1365
  <select id="display" name="display">
1366
- <option value="volume" <?=selected($display, 'volume');?>><?php _e('Total Volume per Period', 'wpmandrill'); ?></option>
1367
- <option value="average" <?=selected($display, 'average');?>><?php _e('Average Volume per Period', 'wpmandrill'); ?></option>
1368
  </select><?php
1369
  }
1370
 
5
  Author: Mandrill
6
  Author URI: http://mandrillapp.com/
7
  Plugin URI: http://connect.mailchimp.com/integrations/wpmandrill
8
+ Version: 1.27
9
  Text Domain: wpmandrill
10
  */
11
  /* Copyright 2012 MailChimp (email : will@mailchimp.com )
284
  ?>
285
  <div class="wrap">
286
  <div class="icon32" style="background: url('<?php echo plugins_url('images/mandrill-head-icon.png',__FILE__); ?>');"><br /></div>
287
+ <h2><?php _e('Mandrill Settings', 'wpmandrill'); ?> <small><a href="options-general.php?page=<?php echo 'wpmandrill'; ?>&show=how-tos">view how-tos</a></small></h2>
288
 
289
  <div style="float: left;width: 70%;">
290
  <form method="post" action="options.php">
366
  ?>
367
  <div class="wrap">
368
  <div class="icon32" style="background: url('<?php echo plugins_url('images/mandrill-head-icon.png',__FILE__); ?>');"><br /></div>
369
+ <h2><?php _e('Mandrill How-Tos', 'wpmandrill'); ?> <small><a href="options-general.php?page=<?php echo 'wpmandrill'; ?>">back to settings</a></small></h2>
370
  <?php
371
  require plugin_dir_path( __FILE__ ) . '/how-tos.php';
372
 
821
  ?>
822
  <div class="inside">
823
  <?php _e('Replace all line feeds ("\n") by &lt;br/&gt; in the message body?', 'wpmandrill'); ?>
824
+ <input name="wpmandrill[nl2br]" type="checkbox" <?php echo checked($nl2br,1); ?> value='1' /><br/>
825
  <span class="setting-description"><em><?php _e('<small>If you are sending HTML emails already keep this setting deactivated.<br/>But if you are sending text only emails (WordPress default) this option might help your emails look better.</small>', 'wpmandrill'); ?></em></span>
826
  </div><?php
827
  }
1345
  ?>
1346
  <label for="filter"><?php _e('Filter by:', 'wpmandrill'); ?> </label>
1347
  <select id="filter" name="filter">
1348
+ <option value="none" <?php echo selected($filter, 'none');?>><?php _e('No filter', 'wpmandrill'); ?></option>
1349
  <optgroup label="<?php _e('Sender:', 'wpmandrill'); ?>">
1350
  <?php
1351
  foreach ( array_keys($stats['stats']['hourly']['senders']) as $sender) {
1363
  </select>
1364
  <label for="display"><?php _e('Display:', 'wpmandrill'); ?> </label>
1365
  <select id="display" name="display">
1366
+ <option value="volume" <?php echo selected($display, 'volume');?>><?php _e('Total Volume per Period', 'wpmandrill'); ?></option>
1367
+ <option value="average" <?php echo selected($display, 'average');?>><?php _e('Average Volume per Period', 'wpmandrill'); ?></option>
1368
  </select><?php
1369
  }
1370