Need code to make EVENT dates on Calendar widget a different color.
5 posters
Page 1 of 1
Need code to make EVENT dates on Calendar widget a different color.
Hello.
This code was given to another user to make the event dates on the Calendar widget a different color:
#calendar a {
background: red;
}
It worked for them but it didn't work for me. I changed "red" to the hex color for crimson and also to the word crimson, but neither worked. I also tried adding !important, but there was no change.
Is my code wrong? I added it to the bottom of the CSS. My site is phoBB2.
Thanks!
This code was given to another user to make the event dates on the Calendar widget a different color:
#calendar a {
background: red;
}
It worked for them but it didn't work for me. I changed "red" to the hex color for crimson and also to the word crimson, but neither worked. I also tried adding !important, but there was no change.
Is my code wrong? I added it to the bottom of the CSS. My site is phoBB2.
Thanks!
Re: Need code to make EVENT dates on Calendar widget a different color.
Try this one
- Code:
gen,gen, b
{
background-color: #DC143;
}
Last edited by Sir. Mayo on August 21st 2013, 3:21 pm; edited 1 time in total (Reason for editing : Code fix)
Re: Need code to make EVENT dates on Calendar widget a different color.
No, thank you for replying but this is not what I want at all.
The code you supplied turns the whole box (the little square box) containing the date to crimson and also the percentage blocks in the POLL widget turn crimson. (crimson = #DC143C.)
Only the numerals of the date, of the event, in the Calendar widget should turn crimson (or the color I choose.) For example, this month 23, 24, and 28 should be crimson.
But thanks for trying to help.
I think the code in my first post is right, but maybe not for phpBB2?
The code you supplied turns the whole box (the little square box) containing the date to crimson and also the percentage blocks in the POLL widget turn crimson. (crimson = #DC143C.)
Only the numerals of the date, of the event, in the Calendar widget should turn crimson (or the color I choose.) For example, this month 23, 24, and 28 should be crimson.
But thanks for trying to help.
I think the code in my first post is right, but maybe not for phpBB2?
Re: Need code to make EVENT dates on Calendar widget a different color.
Try this in your css:
- Code:
a.gen, a.genmed, a.gensmall {
color: #DC143C !important;
text-decoration: none;
}
Re: Need code to make EVENT dates on Calendar widget a different color.
I tried that on mine as well before i posted at first the issue with that is it turns most of the text in the portal red!runawayhorses wrote:Try this in your css:
- Code:
a.gen, a.genmed, a.gensmall {
color: #DC143C !important;
text-decoration: none;
}
but idk if this helps but i know the code to change all the events but the set ones!?
What about this topic you opened here?
https://help.forumotion.com/t126308-calendar-able-to-show-different-events-in-different-colors?highlight=Calendar
I thought this was answered once for you!
Re: Need code to make EVENT dates on Calendar widget a different color.
Read post No #6.
https://help.forumotion.com/t102407-
It should do the trick you're asking Castellana. If you end up in problems post your forums URL.
https://help.forumotion.com/t102407-
It should do the trick you're asking Castellana. If you end up in problems post your forums URL.
Nera.- Energetic
- Posts : 7078
Reputation : 2017
Language : English
Location : -
Re: Need code to make EVENT dates on Calendar widget a different color.
I belive that code is for Phbb3 not phbb2 here forum is Phbb2!
Re: Need code to make EVENT dates on Calendar widget a different color.
BB2::
- Code:
$(document).ready(function() {
$('#calendar_container td.quote:has("a")').css('background-color', 'red');
});
Nera.- Energetic
- Posts : 7078
Reputation : 2017
Language : English
Location : -
Re: Need code to make EVENT dates on Calendar widget a different color.
Thanks to all.
First, let me clear up two things:
@ Sir Mayo - No, that post of mine that you linked is for an entirely different problem. That one is solved, as you point out!
@ Nera - The post you linked in reply #6 above, is the very post that I borrowed the code from. In my first post here, I show some code that you wrote from the topic you linked. I used it because it looked like it would do the trick for me.
So now we are up to the codes offered after that.
Nera's BB2 code is last so I'll try that one and thWho is Online? box.en post back here.
..... a few minutes later .....
@ Runaway horses - your code worked fine, except it also changed the "Today's active topics" and "Administrators, Moderators, Members" colors at the very bottom of the Who is Online box.
First, let me clear up two things:
@ Sir Mayo - No, that post of mine that you linked is for an entirely different problem. That one is solved, as you point out!
@ Nera - The post you linked in reply #6 above, is the very post that I borrowed the code from. In my first post here, I show some code that you wrote from the topic you linked. I used it because it looked like it would do the trick for me.
So now we are up to the codes offered after that.
Nera's BB2 code is last so I'll try that one and thWho is Online? box.en post back here.
..... a few minutes later .....
@ Runaway horses - your code worked fine, except it also changed the "Today's active topics" and "Administrators, Moderators, Members" colors at the very bottom of the Who is Online box.
Re: Need code to make EVENT dates on Calendar widget a different color.
It was not CSS but JS, that's why it has $ signs. And you were suposed to put it in AP > Modules > JS managment and before it enable JS managment and it would work.
(Saw you edited your post now) Take that code I posted here and add it like I explained.
(Saw you edited your post now) Take that code I posted here and add it like I explained.
Nera.- Energetic
- Posts : 7078
Reputation : 2017
Language : English
Location : -
Nera.- Energetic
- Posts : 7078
Reputation : 2017
Language : English
Location : -
Re: Need code to make EVENT dates on Calendar widget a different color.
Okay, now I am in javascript and this is my first time with it.
Should I add the code on to the end of the existing Javascript?
If I don't like it, is Javascript easy to change like CSS? Or will it be a big deal and mess up my forum?
Just have a lot of questions for you because I have never done anything in javascript!
Thanks!!!
Should I add the code on to the end of the existing Javascript?
If I don't like it, is Javascript easy to change like CSS? Or will it be a big deal and mess up my forum?
Just have a lot of questions for you because I have never done anything in javascript!
Thanks!!!
Re: Need code to make EVENT dates on Calendar widget a different color.
Create a new JS by clicking on Create new JS button, mark all pages and save. After it if you don't like it you can just delete the whole new JS. Before that make sure your JS is enabled. On the top of it when you arrive in it press enable JS: YES and save it.
Nera.- Energetic
- Posts : 7078
Reputation : 2017
Language : English
Location : -
Re: Need code to make EVENT dates on Calendar widget a different color.
Okay, thanks for the directions.
I did all like you said but there is no color change at all. Nothing has changed. I refreshed the forum but no change.
What now?
(Thanks for helping me!)
I did all like you said but there is no color change at all. Nothing has changed. I refreshed the forum but no change.
What now?
(Thanks for helping me!)
Re: Need code to make EVENT dates on Calendar widget a different color.
Completely my bad Castellana, didn't check your forum first.
This will work, tried it on your forum:
- Code:
$(document).ready(function() {
$('#calendar_container .forumline td:has("a")').css('background-color', 'red');
$('#calendar_container .forumline td:has("a")').css('background-color', 'red');
});
Example of it working on your forum.
Nera.- Energetic
- Posts : 7078
Reputation : 2017
Language : English
Location : -
Re: Need code to make EVENT dates on Calendar widget a different color.
Thank you but I don't want the whole box to be the color.
Only the numerals of the date, of the event, in the Calendar widget should turn crimson (or the color I choose.) I mean only the numerals such as 23, 24, and 28 should be crimson - not the whole little square box.
Runaway Horses' code came the closest to doing the job but it also changed some other text on the Index page so I could not use it.
Any ideas?
Thanks you so much for continuing to work on this with me. I value your help.
Oh, yes - I definitely DID enable the JS
..... a few minutes later .....
Even though it was not exactly what I thought I wanted, I tried your code and you know what - I like it! I changed the color a couple of times and settled on a "ghost white." I think I will keep this code and use it.
It might still be fun to learn the code for changing the color of ONLY the numerals. but for now I like the code you gave me.
So, thanks once again to you Nera, and to Runaway and Mayo for all your help!
I would be NOWHERE without FM support.
I still can't find the icons to mark this "solved." I will have to make a topic about it.
Only the numerals of the date, of the event, in the Calendar widget should turn crimson (or the color I choose.) I mean only the numerals such as 23, 24, and 28 should be crimson - not the whole little square box.
Runaway Horses' code came the closest to doing the job but it also changed some other text on the Index page so I could not use it.
Any ideas?
Thanks you so much for continuing to work on this with me. I value your help.
Oh, yes - I definitely DID enable the JS
..... a few minutes later .....
Even though it was not exactly what I thought I wanted, I tried your code and you know what - I like it! I changed the color a couple of times and settled on a "ghost white." I think I will keep this code and use it.
It might still be fun to learn the code for changing the color of ONLY the numerals. but for now I like the code you gave me.
So, thanks once again to you Nera, and to Runaway and Mayo for all your help!
I would be NOWHERE without FM support.
I still can't find the icons to mark this "solved." I will have to make a topic about it.
Last edited by Castellana on August 21st 2013, 9:34 pm; edited 1 time in total
Re: Need code to make EVENT dates on Calendar widget a different color.
- Code:
$(document).ready(function() {
$('#calendar_container a.gen').css('color', 'red');
});
- Code:
It might still be fun to learn the code for changing the color of ONLY the numerals.
Take care (:
Nera.- Energetic
- Posts : 7078
Reputation : 2017
Language : English
Location : -
Re: Need code to make EVENT dates on Calendar widget a different color.
Sorry! I thought we were supposed to edit our posts or else it would be called double-posting.
I'll get it right one day! *lol*
Anyway, this is solved now and I found the "solved icon," too. Will miracles never cease?
Both of your codes work great and both are good options for my forum.
Thanks!
I'll get it right one day! *lol*
Anyway, this is solved now and I found the "solved icon," too. Will miracles never cease?
Both of your codes work great and both are good options for my forum.
Thanks!
Re: Need code to make EVENT dates on Calendar widget a different color.
Topic Solved & Locked
Lost Founder's Password |Forum's Utilities |Report a Forum |General Rules |FAQ |Tricks & Tips
You need one post to send a PM.
You need one post to send a PM.
When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.
Similar topics
» Match Main Calendar with Calendar Widget
» How to add and event time to Calendar
» Portal Calendar widget
» How to do this Advanced Hiding Widget Code as well as the Recent Topic's Widget Modification
» Repeat an event every week in calendar
» How to add and event time to Calendar
» Portal Calendar widget
» How to do this Advanced Hiding Widget Code as well as the Recent Topic's Widget Modification
» Repeat an event every week in calendar
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum