diff --git a/e107_core/templates/email_template.php b/e107_core/templates/email_template.php
index 2b969d23f..f61ff199c 100644
--- a/e107_core/templates/email_template.php
+++ b/e107_core/templates/email_template.php
@@ -342,7 +342,7 @@ $EMAIL_TEMPLATE['monthly']['footer'] = $EMAIL_TEMPLATE['default']['footer'];
$EMAIL_TEMPLATE['whatsnew']['name'] = "What's New";
$EMAIL_TEMPLATE['whatsnew']['subject'] = '{SITENAME}: {SUBJECT} ';
$EMAIL_TEMPLATE['whatsnew']['header'] = $EMAIL_TEMPLATE['default']['header']; // will use default header above.
-$EMAIL_TEMPLATE['whatsnew']['body'] = "All the latest news and updates.
{BODY}
To find out more, simply click on the links!";
+$EMAIL_TEMPLATE['whatsnew']['body'] = "Hi {USERNAME},
{BODY}";
$EMAIL_TEMPLATE['whatsnew']['footer'] = $EMAIL_TEMPLATE['default']['footer'];
diff --git a/e107_handlers/e_parse_class.php b/e107_handlers/e_parse_class.php
index 0ea7ac3ee..df910f0d3 100644
--- a/e107_handlers/e_parse_class.php
+++ b/e107_handlers/e_parse_class.php
@@ -247,11 +247,12 @@ class e_parse extends e_parser
* Constructor - keep it public for backward compatibility
still some new e_parse() in the core
*
- * @return void
*/
public function __construct()
{
// initialise the type of UTF-8 processing methods depending on PHP version and mb string extension
+ parent::__construct();
+
$this->init();
$this->initCharset();
@@ -3188,7 +3189,10 @@ class e_parser
private $scriptAccess = false; // nobody.
- public function __construct()
+ /**
+ * e_parser constructor.
+ */
+ public function __construct()
{
$this->init();
@@ -4421,7 +4425,7 @@ return;
{
$value = preg_replace('/^
';
+$NEWS_TEMPLATE['related']['start'] = '{SETIMAGE: w=350&h=350&crop=1}
You Might Also Like
';
$NEWS_TEMPLATE['related']['item'] = '
';
$NEWS_TEMPLATE['related']['end'] = '
';
\ No newline at end of file
diff --git a/e107_plugins/user/e_mailout.php b/e107_plugins/user/e_mailout.php
index 9553e321b..4674045e7 100644
--- a/e107_plugins/user/e_mailout.php
+++ b/e107_plugins/user/e_mailout.php
@@ -169,28 +169,23 @@ class user_mailout
$where[]= "u.`".$selectVals['user_search_name']."` LIKE '%".$selectVals['user_search_value']."%' ";
}
- if (vartrue($selectVals['last_visit_match']) && vartrue($selectVals['last_visit_date']))
+ if (!empty($selectVals['last_visit_match']) && !empty($selectVals['last_visit_date']))
{
- foreach(array(':', '-', ',') as $sep)
- {
- if (strpos($selectVals['last_visit_date'], ':'))
- {
- $tmp = explode($sep, $selectVals['last_visit_date']);
- break;
- }
- }
- $lvDate = gmmktime(0, 0, 0, $tmp[1], $tmp[0], $tmp[2]); // Require dd-mm-yy for now
+ $lvDate = $selectVals['last_visit_date'];
+
+ e107::getDebug()->log(date('r',$lvDate));
+
if (($lvDate > 0) && ($lvDate <= time()))
{
switch ($selectVals['last_visit_match'])
{
case '<' :
case '>' :
- $where[]= "u.`user_lastvisit`".$selectVals['last_visit_match'].$lvDate;
+ $where[]= "u.`user_lastvisit` ".$selectVals['last_visit_match']." ".$lvDate;
break;
case '=' :
- $where[]= "u.`user_lastvisit`>=".$lvDate;
- $where[]= "u.`user_lastvisit`<=".intval($lvDate + 86400);
+ $where[]= "u.`user_lastvisit` >= ".$lvDate;
+ $where[]= "u.`user_lastvisit` <= ".intval($lvDate + 86400);
break;
}
}
@@ -219,6 +214,7 @@ class user_mailout
}
}
$qry .= " FROM `#user` AS u ";
+
if (count($incExtended))
{
$qry .= "LEFT JOIN `#user_extended` AS ue ON ue.`user_extended_id` = u.`user_id`";
@@ -229,9 +225,12 @@ class user_mailout
e107::getMessage()->addDebug("Selector query: ".$qry);
- if (!( $this->mail_count = $sql->gen($qry))) return FALSE;
+ if (!( $this->mailCount = $sql->gen($qry))) return FALSE;
+
+ e107::getDebug()->log($this->mailCount);
+
$this->mail_read = 0;
- return $this->mail_count;
+ return $this->mailCount;
}
@@ -303,7 +302,7 @@ class user_mailout
$var[0]['html'] = $admin->userClassesTotals('email_to', varset($selectVals['email_to'], ''));
$var[1]['html'] = $frm->select('user_search_name', $u_array, varset($selectVals['user_search_name'], ''),'',TRUE)." ".LAN_MAILOUT_47." ".$frm->text('user_search_value', varset($selectVals['user_search_value'], ''));
//$var[2]['html'] = $admin->comparisonSelect('last_visit_match', varset($selectVals['last_visit_match'], ''))." ".$frm->text('last_visit_date', varset($selectVals['last_visit_date'], 0));
- $var[2]['html'] = $admin->comparisonSelect('last_visit_match', varset($selectVals['last_visit_match'], ''))." ".$admin->makeCalendar('last_visit_date', varset($selectVals['last_visit_date'], 0));
+ $var[2]['html'] = $admin->comparisonSelect('last_visit_match', varset($selectVals['last_visit_match'], ''))." ".e107::getForm()->datepicker('last_visit_date', varset($selectVals['last_visit_date'], 0), array('type'=>'datetime'));
$var[1]['caption'] = LAN_MAILOUT_46; // User Search Field.
$var[2]['caption'] = LAN_MAILOUT_56; // User last visit
@@ -347,7 +346,7 @@ class user_mailout
}
if (vartrue($selectVals['last_visit_match']) && vartrue($selectVals['last_visit_date']))
{
- $var[2]['html'] = $selectVals['last_visit_match'].' '.gmstrftime("%D-%M-%Y",$selectVals['last_visit_date']); //FIXME use e107 date function.
+ $var[2]['html'] = $selectVals['last_visit_match'].' '.e107::getParser()->toDate($selectVals['last_visit_date'],'long'); //FIXME use e107 date function.
$var[2]['caption'] = LAN_MAILOUT_56; // User last visit
}
$extFields = $admin->ret_extended_field_list('extended_1_name', varset($selectVals['extended_1_name'], ''), TRUE);