I'm back
I've got it mostly working but can't get the time to convert all the usual unix converters either give a page error or do nothing.
How do I join tables in the Global $db.
It looks like it works at first but my certificate put a different unix date on.
Have a look at to see where I'm going wrong please
$sql = " SELECT *
FROM {facetoface} f
JOIN {facetoface_sessions} fs ON f.id = fs.facetoface
JOIN {facetoface_sessions_dates} fsd ON fs.id = fsd.sessionid
JOIN {facetoface_signups} fsu ON fs.id = fsu.sessionid
JOIN {user} u ON fsu.userid = u.id";
$f2fdate = $DB->get_record_sql('SELECT timefinish FROM {facetoface_sessions_dates}');
certificate_print_text($pdf, $x, $y + 92, 'C', 'freesans', '', 20, $f2fdate->timefinish);
Thanks Jimi