Jump to content

Pulling datestamp into html email ? Help required


Dicko_md

Recommended Posts

function SendReminder($info, $isadvanced) {
 $sitename = GetConfig('sitename');
 $siteurl = GetConfig('siteurl');
 $comment = stripslashes($info['shcomment']);
 $stub = db_select('ar_members', 'id', "id=$info[userid]");
 if (!mysql_num_rows($stub)) {
  db_delete('ar_notify', "id=$info[id]");
  return;
 }
 $tzoffset = GetUserOffset($info['userid']);
 $formdate = time()-$tzoffset;
 $formdate = date("l jS F Y H:i", $formdate);
        $timestamp = date("l jS F Y H:i", $info['date_field']);
 $timecreated = date("l jS F Y H:i:s", $info['timecreated']-$tzoffset);

This gets sent in an email but its blank

$message .= "<tr style='background: #eee;'><td><strong>Event Date:</strong> </td><td>" .$timestamp. "</td></tr>";

 

Ive tried adding the $timestamp line in but this still doesn't work.

 

If I have $formdata in the $message email it shows the time the email was created not the time of the event.

 

The date_field is the column in the database where I am getting the data from. Its a unix style date.

 

Thanks in advance

 

Martyn

Hi yes I have run a echo and it says the time the actual reminder was set for.

$message .= "<tr style='background: #eee;'><td><strong>Event Date:</strong> </td><td>" .$timestamp. "</td></tr>";

Its this line that's not playing ball. Its just empty in the email but all the other info is there.

 

Thanks

 

Martyn

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.