Hi,
i'm still trying to build a script that will display the upcomming events from a table (event) containing infos like title ($meuh2) and date infos ($newdate or $dateline for unix-timestamp)
here's a part of the code:
$query = "SELECT e., t., p.* FROM event AS e, thread AS t, post AS p WHERE e.dateline_from > UNIX_TIMESTAMP() AND t.forumid = 16 AND t.threadid = p.threadid AND p.parentid = 0 AND t.title LIKE '$yo' AND t.forumid = '16' AND e.eventid = t.lv_vb_eventforums_eventid ORDER BY e.dateline_from DESC LIMIT $affichage";
$res = mysql_query($query) or die(mysql_error());
while($row = mysql_fetch_array($res)) {
$dateline = $row["dateline_from"];
$newdate = vbdate($vbulletin->options['dateformat'], $dateline, 0);
}
$blah2x = $row["title"];
$meuh2 = substr( $blah2x, 0, 200 );
echo "<table><tr><td>date: $newdate</td><td> event: $meuh2</td></tr></table>";
What I would like to do is the following:
at every SUNDAY, write between two tables (between two events) something like "EVENTS FOR THIS WEEK: From sunday 3 to saturday 10"
and of course, write this only at the start of a week and not between each event. But, even if a whole month is empty and has no events, it should still display the message for each week
thanks for the help!