Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.javascript > #23752

Re: help with plugin Full calendar

From Gloops <gloops@zailes.invalid.org>
Newsgroups comp.lang.javascript
Subject Re: help with plugin Full calendar
Date 2014-03-31 10:04 +0200
Organization Serveur de salon
Message-ID <lhb7is$2sb$1@usenet.pasdenom.info> (permalink)
References <0dc7e8a9-dbe7-4d3d-a92a-236e44544419@googlegroups.com>

Show all headers | View raw


Luis Vicente wrote, on 21st March 2014 16:42 UTC + 2 :
> Hi!. I am using the plugin Full Calendar and I have this trouble:
>
> I need to change the color, for example, of the day 1 in march(only this day). But when I change the color, april 01 also changes. I do not how to manage that.
>
>
> This my function to change the color of only march 01:
>
> dayRender: function (date, cell) {
>           var today = new Date();
>      var end = new Date();
>      end.setDate(1,3,14);
>
>      if (date.getDate() === end.getDate()) {
>          cell.css("background-color", "red");
>      }
>


Hello,

Without knowing all the ins and outs, I see you change the format of the 
cell when it is set to a certain date, but you do not set it back when 
the date is different.

It could look like something like this :

       if (date.getDate() === end.getDate()) {
           cell.css("background-color", "red");
       }
       else
       {
           cell.css("background-color", "white");
       }

Back to comp.lang.javascript | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

help with plugin Full calendar Luis Vicente <luisvicent91@gmail.com> - 2014-03-21 08:42 -0700
  Re: help with plugin Full calendar "Evertjan." <exxjxw.hannivoort@inter.nl.net> - 2014-03-21 17:22 +0100
    Re: help with plugin Full calendar Luis Vicente <luisvicent91@gmail.com> - 2014-03-21 09:49 -0700
      Re: help with plugin Full calendar "Evertjan." <exxjxw.hannivoort@inter.nl.net> - 2014-03-21 18:01 +0100
  Re: help with plugin Full calendar Gloops <gloops@zailes.invalid.org> - 2014-03-31 10:04 +0200
    Re: help with plugin Full calendar "Evertjan." <exxjxw.hannivoort@inter.nl.net> - 2014-03-31 10:40 +0200

csiph-web