[thelist] Update styles based on date with PHP?
Jono
jono at charlestonwebsolutions.com
Mon Sep 18 12:34:56 CDT 2006
I have a number of events listed in an HTML table:
<table>
<tr>
<td class="format"><a href="#" class="external">Talk Like a
Pirate Day</a></td>
<td>September 19</td>
<td class="last">Charleston, SC</td>
</tr>
<tr class="alt">
<td class="format"><a href="#" class="external">Event Number
Two</a></td>
<td>October 19–22</td>
<td class="last">City, State</td>
</tr>
<tr>
<td class="format"><a href="#" class="external">Event Number
Three</a></td>
<td>November 11–13</td>
<td class="last">City, State</td>
</tr>
</table>
I would like to apply the style - .past { text-decoration: line-through;
} - to the events that have already occurred/past. Ideally, each
<td>'s content would get the style applied if it's date had past. Is
there a way to do this using PHP - a simple, not-super-genius-like
approach would be best as I am still learning PHP.
More importantly, if there is a (preferably PHP) calendar app. (I know
I've read about a bunch, but I am not PHP savvy enough to pick the best
of the bunch) that I can use to handle this, that would probably be
better. The most important thing would be ease of use from an
administration and end user perspective, and the ability to adapt the
look/feel of the site the calendar/event organizer will go into.
Simply put, I need a better way to maintain calendar/events type
information on a single page.
Thanks,
Jono
More information about the thelist
mailing list