Forums / All Other Contributions/Addons / Email Archive Manager - D/M/Y Date issue:

Email Archive Manager - D/M/Y Date issue:

Locked

Views: 1,765

Results 1 to 1 of 1
This thread is locked. New replies are disabled.
27 Jul 2010, 4:26 AM
#1
rlexyd avatar

rlexyd

Zen Follower

Join Date:
Nov 2006
Location:
Sydney, Australia
Posts:
474
Plugin Contributions:
0

Email Archive Manager - D/M/Y Date issue:

Hi all,

I have installed the Email Archive Manager on my Zen-cart 1.3.9d and it seems to be working fine.

I changed the dates from the 2 english.php files to suit D/M/Y instead of M/D/Y.

It still works fine, the only issue I can see is that when I trim the email archive it is deleting all archived emails, even if I choose a different date!

I checked the Admin/email_history.php and changed the dates "d", "m" & "y".

Did I do the correct thing? If not, what else need to be changed?

Thank you for your help.

Best Regards,

Below is what the changed code looks like:

if ($action == 'trim_confirm') {
$age = $_GET['email_age'];
if ($age == '1_months') {
$cutoff_date = date("d-m-Y", mktime(0, 0, 0, date("d") - 1, date("m"), date("Y")));
}
if ($age == '6_months') {
$cutoff_date = date("d-m-Y", mktime(0, 0, 0, date("d") - 6, date("m"), date("Y")));
}
elseif ($age == '1_year') {
$cutoff_date = date("d-m-Y", mktime(0, 0, 0, date("d"), date("m"), date("Y") - 1));
}

AND

<?php echo zen_draw_hidden_field('action', 'trim_confirm'); ?> <tr> <td><table border="0" cellspacing="0" cellpadding="2"> <tr> <td class="main"><?php echo zen_draw_radio_field('email_age', '1_months', true) . RADIO_1_MONTH . ' (' . date("d/m/Y", mktime(0, 0, 0, date("d") - 1, date("m"), date("Y"))) . ')'; ?></td> </tr> <tr> <td class="main"><?php echo zen_draw_radio_field('email_age', '6_months') . RADIO_6_MONTHS . ' (' . date("d/m/Y", mktime(0, 0, 0, date("d") - 6, date("m"), date("Y"))) . ')'; ?></td> </tr> <tr> <td class="main"><?php echo zen_draw_radio_field('email_age', '1_year') . RADIO_1_YEAR . ' (' . date("d/m/Y", mktime(0, 0, 0, date("d"), date("m"), date("Y") - 1)) . ')'; ?></td> </tr>

AND

<td class="pageHeading" align="right"><?php echo date('l D m, Y', time()); ?></td>

*Zen Cart eCommerce Solution - Putting the Dream of Owning an Online Business within reach of anyone!