View previous topic :: View next topic |
Author |
Message |
chris_motch
Joined: 14 Mar 2006 Posts: 3
|
Posted: Tue Mar 14, 2006 7:48 pm Post subject: Ability to determine of calendar is open? |
|
|
Is there a way to be able to determine if the calendar is already open. I'm working on a site that if the user clicks multiple times on the date field, it only pop's up the calendar once and keeps it open for any subsequent clicks on the field. Plus is there a way to prevent the calendar from closing if the user clicks anywhere on the page, i.e keeping it open until either they close it manually or select a date?
Thanks
|
|
Back to top |
|
|
calendarxp Site Admin
Joined: 30 Jan 2005 Posts: 409
|
Posted: Tue Mar 14, 2006 8:53 pm Post subject: |
|
|
To determine whether it's open, simply call gfPop.fIsShown(), e.g.
Code: | <input type=button value=test onclick="if (self.gfPop&&gfPop.fIsShown()) alert("calendar is visible.");return false;"> |
For the manual-close issue, it's supposed to keep open if you set the gbAutoClose option to false. But obviously there is a bug that still closes the calendar if you click anywhere on the page. We'll be releasing a new version to fix this bug - most likely by tomorrow.
_________________ Copyright 2003-2011 Idemfactor Solutions, Inc. All rights reserved. |
|
Back to top |
|
|
calendarxp Site Admin
Joined: 30 Jan 2005 Posts: 409
|
Posted: Wed Mar 15, 2006 3:51 am Post subject: |
|
|
New version has been released, please download 9.7.290 and give it a try.
When gbAutoClose is set to false, calendar won't close unless you click on a close button. You may simply add fHideCal() into fAfterSelected() plugin to close the calendar when a date is selected. e.g.
Code: | function fAfterSelected(y,m,d,e) {
fHideCal();
} |
_________________ Copyright 2003-2011 Idemfactor Solutions, Inc. All rights reserved. |
|
Back to top |
|
|
chris_motch
Joined: 14 Mar 2006 Posts: 3
|
Posted: Wed Mar 15, 2006 8:00 pm Post subject: |
|
|
That worked great, actually the fix that was implemented made a lot my existing code obosolete and solved a few problems I was having.
Quick question, when I set a date range and want to disable selecting certain dates, right now I have a little x showing where dates cannot be selected, how can I set it to be greyed out instead?
Thanks
|
|
Back to top |
|
|
calendarxp Site Admin
Joined: 30 Jan 2005 Posts: 409
|
|
Back to top |
|
|
|