I am trying to compare dates and apply a class based on the result.
<div class="" id="date" title = <%... %> />
The title is the date and time returned from a query (IE. Mar 23, 2016 05:00 AM
). I would like to check if the DATE is less than today (ie Mar 23, 2016
). I am sure this will require a function, but was hoping there may be a shortcut I am missing. Any help is appreciated. Not very proficient in jQuery yet.
EDIT:
Maybe I am going about this wrong. As stated this is a resultset from a query that is in a nested repeater. If the date returned is less than the current date (time is of no consequence) then I want to add a class to the given label. this will be repeated for each returned result. Should I look at doing this via Java script post databinding or code-behind (C#)? Just getting back into programming after several years of DBA work. Thanks again in advance