Page 1 of 1

cannot display ''today'' in Calendar module

Posted: Wed Nov 29, 2006 2:28 am
by Foton
Just installed the Calendar module. It's a pitty there is no manual, but through this forum I got it up and running (thanks to Mark!)
There is only 1 thing I am looking for over hours now;
I just want to change te background of today's day.
It is called ''calendar-today'' and I changed the css like this;
#cmscal .calendar-today{
color: red; font-weight:bold;
}
and I used the tag;
{cms_module module="Calendar" table_id="cmscal"}
but it will not change. Has anyone got it working or can point me to the right direction?
Cheers & regards.

Re: cannot display ''today'' in Calendar module

Posted: Wed Nov 29, 2006 2:40 am
by Dr.CSS
Try background-color...

#cmscal .calendar-today{
background-color: red; font-weight:bold;
}

Re: cannot display ''today'' in Calendar module

Posted: Wed Nov 29, 2006 7:58 am
by Foton
Sorry, but the real question/problem is that in the calendar-template there is no ''calendar-today'' So the stylesheet is OK, but there is no request for calendar-today...
I hope I made myself clear.
Thanks for the quick response!

Re: cannot display ''today'' in Calendar module

Posted: Wed Nov 29, 2006 5:23 pm
by Dee
In the default installed template the current day is shown as so, I'm styling it with:

Code: Select all

table.calendar .calendar-today
{
  background-color: #8080ff;
}
The class is not added in the template, but in the module code (function.display.calendar.php, line 193)

Code: Select all

$today = date('j');
$days[$today]['class'] .= ' calendar-today';

Re: cannot display ''today'' in Calendar module

Posted: Wed Nov 29, 2006 10:01 pm
by Dr.CSS
Well if you did a default install and you copied the CSS rules from the calendar module and used the tag...

{cms_module module="Calendar" table_id="cmscal"}

Then you should get this, I used your tag with your styling...

http://multiintech.com/cmsms4/index.php?page=calendar

Re: cannot display ''today'' in Calendar module

Posted: Thu Nov 30, 2006 11:57 pm
by Foton
Well, I re-installed the module and used the ''help - part 2'' again. Now the background is showing up again. So I probably messed up something during re-designing the template/stylesheet. I realy do not know what I messed up, nut I will try to get the same result again.
Thanks everybody for your help. Very appreciated!  8)

Re: cannot display ''today'' in Calendar module

Posted: Mon Dec 04, 2006 10:13 am
by Foton
I inserted a linebreak before an if/else-statement. That killed the backgroundcolor....