Menu
Welcome, Guest
Username: Password: Secret Key Remember me
Welcome to the Developer forum!
Get all your questions answered here. Learn to integrate calendar in your application.
  • Page:
  • 1

TOPIC: Problem to color group

Problem to color group 14 years 11 months ago #209

  • losfigatto
  • losfigatto's Avatar Topic Author
  • Offline
  • Fresh Boarder
  • Fresh Boarder
  • Posts: 2
  • Thank you received: 0
I'm working with web2cal basic version and I would view groups of events with different color.
I try with this code:
var events = new Array();
...
var colors = new Array();
colors.push({color:"redTemplate",css:"redDiv"});

var groups = new Array();
groups.push({groupId:1,name:"group_1",color: colors,events:events});
ical.render(groups);

but it don't work. On firefox I get error "Z.color is undefined".
SomeOne can write an example that describe a way to view groups of events to different colors or Can explain how to do.
Thanks!

Please Log in to join the conversation.

Re:Problem to color group 14 years 11 months ago #210

  • ragskarnam
  • ragskarnam's Avatar
  • Visitor
  • Visitor
Hey,

This is how I did and it works

var group = {
        name: "Club 2",
        groupId: "200",
        events: events,
	color:SSPlotter.colors[5]
    }; 

OR - THIS ALSO WORKS. 
var group = {
        name: "Club 2",
        groupId: "200",
        events: events,
	color:{color:"purple", css:"dirtypurple"}
    }; 

I am using Premium version 1.3.7 and It works well. I haven't tried it in other versions. Good Luck!

Please Log in to join the conversation.

Re:Problem to color group 14 years 11 months ago #212

  • losfigatto
  • losfigatto's Avatar Topic Author
  • Offline
  • Fresh Boarder
  • Fresh Boarder
  • Posts: 2
  • Thank you received: 0
But I can insert a color object which not present in SSPlotter?
example: {color: "MyColor",css:"MyColorDiv"}

thanks a lot

Please Log in to join the conversation.

  • Page:
  • 1
Time to create page: 0.060 seconds
Powered by Kunena Forum

LATEST IN FORUM

  • No posts to display.

ABOUT US