How to disable the past dates of my calendar??

laki , February 10 2012
l
laki

Hi,

I'm using ChronoForm 1.3/ V3.1 RC5.2, and I need to disable the past dates of my calendar. I'm using this form for a reservation site so it should active only present date and future dates. How can I do it? And past dates should be disable to select too.

GreyHead

Hi laki,

You can use the direction option in the DatePicker Options box on the form general tab. if you use

				{ direction: 1 }
				
the calendar will only accept future dates. See more here

Bob

NB for other readers, this does not work for the ChronoForms v4 calendar.

l
laki

Hi,

Thanks for your reply. I need small help from you. Where do i need to put that code? I upload a file please let me is that d correct place to do the change.

Attachments
Untitled-1.jpg
Untitled-1.jpg
(35.53 KiB)
2523 Downloads/Views
GreyHead

Hi laki,

Yes that the right box. Try

				classes: ['dashboard'], direction: 1
				

Bob

l
laki

Hi Bob,

I try it, But it doesn't work for me. Did I miss anything? Please help me.

GreyHead

Hi laki,

It works perfectly here.

Bob

Attachments
14-02-2012 11-55-42.png
14-02-2012 11-55-42.png
(14.27 KiB)
2467 Downloads/Views
l
laki

Im using ChronoForm 1.3/ V3.1 RC5.2 is there ant bug in it?

l
laki

I used below code,

<div class="form_item">
<div class="form_element cf_datetimepicker">
<label class="cf_label" style="width: 58px;">Check in</label>
<input type="text" value="" class="cf_datetime required" readonly name="theDate" size="20" style="color:#000;margin-right:5px" id="date_01"><input type="button" title="Please select the check in date" value="" id="" onclick="displayCalendar(document.forms[0].theDate,'yyyy/mm/dd',this)" size="20" class="calic">

</div>
<div class="cfclear">&nbsp;</div>
</div>

I think some thing wrong in here. Could you please help me with this

l
laki

Hi Bob,
Any solution for this??????

If there's no solution I might go for latest Chronoform. And please tel me how to show calendar icon in Chronoforms_V4_RC3.11_J1.6 component?????

GreyHead

Hi laki,

Form the code you posted there you aren't using the ChronoForms datepicker so it's not surprising that the ChronoForms code doesn't work with it. You'll need to check what calendar you are using and see what the documents say.

The ChronoForms v4 calendar doesn't display an icon.

Bob

l
laki

Hi Bob,

Ya that's correct from my code its so difficult to do what I want. I have try latest ChronoForms and I hope there's no option to display the calendar icon, So how can I show the calendar icon next to the text lable. And please let me know will it display in IE??????

GreyHead

Hi Laki,

I'm sorry, I no longer understand what your question is.

Bob

l
laki

ok it simple how can I display the calendar icon in date picker? Will it be display in IE browser? Currently calender is not working in IE browser

GreyHead

Hi laki,

The ChronoForms v3 calendar displays an icon and will work in IE unless there is some other problem.

The ChronoForms v4 calendar does not display an icon.

Bob

l
laki

Hi Bob,

Another question with ChronoForms 4.0 RC3.11. Where Should I place "direction: 1"? is it "DateTime Picker config" text box????????

GreyHead

Hi laki,

The ChronoForms v4 calendar is different and does not use the direction option. It does have a minDate option which is similar. Please see this thread.

Bob

l
laki

Hey Bob,

Im little bit confuse with ChronoForms 4.0 RC3.11, please let me where should I put 'direction: 1'. please check the attachment, is that the correct place? if not please let me know.

thx

Attachments
ex.jpg
ex.jpg
(38.5 KiB)
1188 Downloads/Views
l
laki

sorry bob I just saw your reply. forget about the previous post.

l
laki

Thx Bob, this works perfectly.

l
laki

Hi Bob,

I have another small question, I'm using ChronoForms for a hotel reservation website and now I want to disable past dates of check out date, Ex. If check in date is 05 Sep 2012 Check out date should be future date. Users are not allow to select back date from the check in date. Hope you got my point. Please let me know how to do this???????

Thank you.

Laki

Powered by ChronoForums - ChronoEngine.com

ChronoForms Book

The ChronoForms Book, written for ChronoForms v3 contains 350 pages of invaluable ChronoForms How-tos hints and tips.

Note: many of the ideas can be used in ChronoForms v4 but the admin interface is very different and code examples may need to be modified.

SSL

Members Login

 

2CheckOut.com Inc. (Ohio, USA) is an authorized retailer for
goods and services provided by ChronoEngine.com