Important alert: (current site time 7/15/2013 11:58:23 AM EDT)
 

winzip icon

Advanced calender control

Email
Submitted on: 8/11/2005 6:49:45 AM
By: Jonathon Cebula  
Level: Advanced
User Rating: By 28 Users
Compatibility: JavaScript
Views: 26323
author picture
(About the author)
 
     Create custom calendar control using Javascript. You can modify the heading, colours fonts, click events and year range. Please vote for this code if you like it and use it. Thanks. http://www.webelectrix.com Please Note: this code can only be used by direct permission of the author, or Webelectrix. This code is only allowed to be used in it's original format, and is only licensed for free use, for a full license contact Webelectrix.

 
winzip iconDownload code

Note: Due to the size or complexity of this submission, the author has submitted it as a .zip file to shorten your download time. Afterdownloading it, you will need a program like Winzip to decompress it.Virus note:All files are scanned once-a-day by Planet Source Code for viruses, but new viruses come out every day, so no prevention program can catch 100% of them. For your own safety, please:
  1. Re-scan downloaded files using your personal virus checker before using it.
  2. NEVER, EVER run compiled files (.exe's, .ocx's, .dll's etc.)--only run source code.

If you don't have a virus scanner, you can get one at many places on the net including:McAfee.com

 
Terms of Agreement:   
By using this code, you agree to the following terms...   
  1. You may use this code in your own programs (and may compile it into a program and distribute it in compiled format for languages that allow it) freely and with no charge.
  2. You MAY NOT redistribute this code (for example to a web site) without written permission from the original author. Failure to do so is a violation of copyright laws.   
  3. You may link to this code from another website, but ONLY if it is not wrapped in a frame. 
  4. You will abide by any additional copyright restrictions which the author may have placed in the code or code's description.


Other 4 submission(s) by this author

 


Report Bad Submission
Use this form to tell us if this entry should be deleted (i.e contains no code, is a virus, etc.).
This submission should be removed because:

Your Vote

What do you think of this code (in the Advanced category)?
(The code with your highest vote will win this month's coding contest!)
Excellent  Good  Average  Below Average  Poor (See voting log ...)
 

Other User Comments

7/2/2001 9:14:21 AMGary Choma

Very nice code!! I had to modify it slightly to avoid a javascript error when it first loaded - it seems to be a bug in IE, NOT your code, as the syntax is correct. It may be a timing thing when using DHTML as the page loads. I had to move the "caltoday()" and "updatecalendar()" calls out of the "calenar()" function, into the onload event of the document: This causes that code to execute after the document loads, and seems to alieviate the problem IE 4 was giving me. This is one of the best calendar examples I've seen!
(If this comment was disrespectful, please report it.)

 
7/6/2001 9:33:33 AMSebastien D'Errico

Thanks ! It works fine for me !
(If this comment was disrespectful, please report it.)

 
7/25/2001 5:49:05 AMAndrew Miles

After viewing all the popup calendars I could find, this is definitely the best. I also downloaded the popup window script, and the two together are just brilliant.

My only problem now is that I have very little knowledge of java and I don't know how to reprogram the click function to introduce the date into the date field.

Can anyone help me. My email address is sales@amiles.net
(If this comment was disrespectful, please report it.)

 
7/25/2001 6:33:52 AMJonathon Cebula

Thanks for you comment Andrew, Here is the code to do what you want: Prerequesite: Insert into your html page an input box ie: Then insert this code in the click function called message at the start of the calendar code: function message(cell) { inpdate.value=cellday[cell]; } And thats it! one thing to remember is that if you put the input box in a form, you'll have to include the ID for that in your jscript. Example: The Javascript would be: function message(cell) { inpdate.value=cellday[cell]; } Hope that all makes sense. Regards, Jonathon Cebula Webelectrix.com
(If this comment was disrespectful, please report it.)

 
8/3/2001 4:52:49 PMRyan

I was wondering how to get the script to display the date in the text box differently... I want to make it MM-DD-YYYY with the
(If this comment was disrespectful, please report it.)

 
8/3/2001 5:41:46 PMRyan

sorry my last post got cut off...
i want it to display the date like that with the -'s or /'s... thans for your time....
(If this comment was disrespectful, please report it.)

 
8/8/2001 4:50:40 AMJonathon Cebula

Okay, this is easy to change, if you look through the code for this line:

cellday[cell]=strday+strmon+stryear

its located in the subroutine 'setday', thats commented 'Set day variables' if you change this line of code to:

cellday[cell]=strmon+"/"+strday+"/"+stryear

Then you'll find it'll be formated MM/DD/YYYY, or:

cellday[cell]=strmon+"-"+strday+"-"+stryear

will format it MM-DD-YYYY.

Hope that all makes
sense.

Any probs let me know,

Jonathon
Cebula
Webelectrix.com

(If this comment was disrespectful, please report it.)

 
11/27/2001 10:31:47 AMGary

Can you tell me if this code allows for the input of events that occur on a certain date?
(If this comment was disrespectful, please report it.)

 
12/9/2001 7:46:29 PMMathew

The code looks fairly good and It's certainly the best example of a calendar pop-up I've seen floating around. Just want to cover myself for copyright before I use it in my Web App, If you've got any restrictions on the use of this code could you please let me know?

public e-mail address: grassfire@hotmail.com.

thanks,

Mathew
(If this comment was disrespectful, please report it.)

 
1/9/2002 7:58:29 AMDhanashree Panse

hi,
that was really a nice piece of code. but the problem which i am facing is with Netscape 4.7. This code is not running in Netscape. Can u tell me the modifications required in the code so that it becomes Netscape compatible too ?

regards,
Dhanashree
(If this comment was disrespectful, please report it.)

 
1/9/2002 8:00:37 AMDhanashree Panse

hi...
that was a nice piece of code !!
But I am facing a problem with Netscape 4.7. Could you pl. let me know what changes I need to do in the code so that it becomes Netscape compatible too?

regards,
Dhanashree
(If this comment was disrespectful, please report it.)

 
4/29/2002 7:27:26 AMJ Kang

I love this one.

How can I get the date value selected when I open this calendar and select one?

Thanks.
(If this comment was disrespectful, please report it.)

 
4/29/2002 7:38:00 AMJonathon Cebula

Hi all,

Not this calendar is for reference only. I'm a freelance programmer, therefore I would have to charge for any advice I give. The code is fully commented and most responses above should help with any querys, I have a version which is fully compatible with all netscape versions. I will post when this is released.
(If this comment was disrespectful, please report it.)

 
7/12/2002 5:53:30 PMYvonne

This is a really great script.

Great Job Jonathon!!!
(If this comment was disrespectful, please report it.)

 
2/20/2003 3:01:07 AM

Very nice calender! I would like to modify it and use it in my assignment. Thus i would like to seek your approval.
My email is: guotzi@yahoo.co.uk

Thanks!
(If this comment was disrespectful, please report it.)

 
1/16/2004 12:32:42 PMJonathon Cebula

Thanks everyone.
(If this comment was disrespectful, please report it.)

 
2/4/2004 9:05:34 AM

This is the Best code i have found, can anyone tell me how to make it so when I click the date it will open a url?
(If this comment was disrespectful, please report it.)

 
4/13/2005 3:10:39 PMSam Moses The Old Account

Nice code, it gave me some interesting insight into client side calendar development. And I hate to nitpick, but it's not a Java program. It's a Javascript program. Huge difference. The program announces that it's Java based when you run it, and it's not. Just a thought. Other than that, great job!
(If this comment was disrespectful, please report it.)

 
4/14/2005 2:31:28 AM

really good, thx
(If this comment was disrespectful, please report it.)

 
4/14/2005 4:07:47 AMJonathon Cebula

Hi Sam,

If your refering to the title at the top of the calendar, then it's because this is a conversion of my original, Java Applet Calendar. When it became apparent that Java Applets where becoming obsolete (thanks to the battle that made it illegal to easily distribute the runtimes) I thought I would make a better alternative. Hence the title bar still being as per the original!

Thanks to everyone for there kind words.
(If this comment was disrespectful, please report it.)

 
9/2/2005 5:05:08 AMTaci TIRSAK

nice code, but dont work on firefox ??
(If this comment was disrespectful, please report it.)

 
9/2/2005 9:24:22 AMJonathon Cebula

Hi Taci TIRSAK,

The code is free, for a fully compatible version I charge, this is for reference to get you started, not for the copy and paste coder...I have zero respect for those guys.
(If this comment was disrespectful, please report it.)

 
10/29/2006 4:50:23 AMRommel

It does not work with mozilla firefox... How can i make it work with mozilla? Please help? Thanks
(If this comment was disrespectful, please report it.)

 
1/21/2007 8:06:47 PMsherry

wow...finally found a code that is similar to what I want a calendar to be, but how can I put in background color for public holidays?
(If this comment was disrespectful, please report it.)

 
1/21/2007 8:19:10 PMsherry

Hi....nice code! Can I use it in my webpage? By the way, is it possible to add in background color for public holiday? Thank you!
(If this comment was disrespectful, please report it.)

 

Add Your Feedback
Your feedback will be posted below and an email sent to the author. Please remember that the author was kind enough to share this with you, so any criticisms must be stated politely, or they will be deleted. (For feedback not related to this particular code, please click here instead.)
 

To post feedback, first please login.