QUICK NEWS

{NEW} - A new css video is up.

{OLD} - New video courtesy of Skhilled, Thanks for posting it up.

Video of the moment:


Internal Links

SMF Sites

Quick Info

.calendar_today Issues

Started by Skhilled, Aug 13, 2022, 12:07 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Skhilled

I'm pretty sure I've done something wrong somewhere but I can't change the background for the current date in the calendar:

https://www.jpr62.com/demos212/index.php?action=calendar

Bigguy

The number is bolder. Maybe investigating that will help you solve this.
"It's the American dream....cause ya have to be asleep to believe it." - George Carlin

Bigguy

I just did it in the inspect web developer thing in FF.
"It's the American dream....cause ya have to be asleep to believe it." - George Carlin

Bigguy

You might have to do it inline though I'm not sure. You could add maybe:

days calendar_today
background-color: red;

to the css and see what happens.
"It's the American dream....cause ya have to be asleep to believe it." - George Carlin

Skhilled


Bigguy

Make your own:

.days calendar_today

or:

#days calendar_today

Then add that line I said. All I did was go to inspect...after that in the second window at the bottom under "This element". I typed in:

background color: red;

It changed it. I also noticed in the first window it had added to the:

Td class= "days windowsbg"

now one of them says Td class= "days calendar_today" style= "background-color: red;" I will upload a screenshot of what I see.
"It's the American dream....cause ya have to be asleep to believe it." - George Carlin

Bigguy

"It's the American dream....cause ya have to be asleep to believe it." - George Carlin

Skhilled

Ok, I'm not sure what is wrong but it does work with the "element" but not with either of the codes you've given me. The funny thing is that it used to work before but now I have no idea what's going on. :o

To make matters works, this kooky keyboard keeps acting up on me. >:(  Me thinks that's part of the problem if not the whole problem.

Bigguy

"It's the American dream....cause ya have to be asleep to believe it." - George Carlin

Skhilled

Ok, I sort of found out what's going on. LOL I had changed all of the days' background color so they would all be the same and that's what is preventing it from showing. Now, I have to narrow it down to getting all of the backgrounds the same color except for the current day.

Bigguy

"It's the American dream....cause ya have to be asleep to believe it." - George Carlin

Skhilled

Almost... LOL I did forget to mention this should be the code for it:

#main_grid .calendar_today {
  background: red;
}

But it only works for the main grid. I'm having the same issue with the month grid now and it won't change. I may have to start over so I can figure out what's wrong. The good thing about starting over only for the calendar.css file is that it's a small file. LOL

Skhilled


Bigguy

It looks good, but when you hover over today's date the number is hard to see cause it turns white. Also, the 31st of July looks highlighted a bit, along with the first second and third of September for some reason. They don't look like today's date but they are white.
"It's the American dream....cause ya have to be asleep to believe it." - George Carlin

Skhilled

#14
Quote from: Bigguy on Aug 14, 2022, 08:36 AMIt looks good, but when you hover over today's date the number is hard to see cause it turns white.
Ah! I didn't notice that...thanks!

EDIT: Fixed. :)

Quote from: Bigguy on Aug 14, 2022, 08:36 AMAlso, the 31st of July looks highlighted a bit, along with the first second and third of September for some reason. They don't look like today's date but they are white.
That's because they are "disabled" for the current month. The one at the top is from the previous month and the ones at the bottom are for next month. That is how SMF and a lot of themes do it but I was debating on making them the same color as the days of the current month.