[SOLVED] Highlight current day in CGCalendar

Have a question or a suggestion about a 3rd party addon module or plugin?
Let us know here.
Post Reply
punkn00dlez
Forum Members
Forum Members
Posts: 13
Joined: Mon Jul 20, 2009 5:28 pm

[SOLVED] Highlight current day in CGCalendar

Post by punkn00dlez »

Is there a way to highlight the current day in CGCalendar?  I've got my template set up correctly right now - but only by removing things and saying "oops, let's put that back in" so I didn't really learn too much about how to make it actually do things.  Is the highlighting actually doable?
Last edited by punkn00dlez on Tue Sep 29, 2009 5:03 pm, edited 1 time in total.
User avatar
paulbaker
Dev Team Member
Dev Team Member
Posts: 1465
Joined: Sat Apr 18, 2009 10:09 pm
Location: Maidenhead, UK
Contact:

Re: Highlight current day in CGCalendar

Post by paulbaker »

If you look at the HTML source of your calendar page you should see

Code: Select all

<td class="calendar-today">5</td>
by today's date.  So you need to create a class in your style sheet called this.

In my case it looks like this:

Code: Select all

#cal-calendar .calendar-today
{
  background-color: #FFFACD;
}
so I have a nice light yellow background for today (and white for all other days).

(#cal-calendar is the DIV name for the table that shows this month).
To copy System Information to the forum:
https://docs.cmsmadesimple.org/troubles ... nformation

CMS Made Simple Geekmoots attended:
Nottingham, UK 2012 | Ghent, Belgium 2015 | Leicester, UK 2016
punkn00dlez
Forum Members
Forum Members
Posts: 13
Joined: Mon Jul 20, 2009 5:28 pm

Re: Highlight current day in CGCalendar

Post by punkn00dlez »

Wow, sorry it took way to entirely long to get back to you, I was unaware anyone had replied.  I found that little tidbit already inside my css (I just used the sample one and modded it to suit my needs).  I changed the color and it works great.  Thanks for the heads up.
Post Reply

Return to “Modules/Add-Ons”