Displaying a Calendar on a Form Text Field (Pro only)

When you offer a form to visitors on a website, it makes it a lot easier for the visitor to choose a date from a calendar popup (see screenshot below) rather than have to enter the date manually. This can be done in Freeway by using the CalenderView Action.



Download and install the Action from http://www.actionsforge.com/actions/view/109-calendarview and then all you need to do to use it on your form is to apply the Action to a text field item. To do this, draw the text field you want to use the Calendar with, go to Item>Actions and choose CalendarView.

Preview the site in a browser and click on the text field which has the Action applied to it. You should see a calendar popup appear on top of the text field where the visitor can choose their date (clicking on the “<” or “>” will change the month, clicking on the “<<” or “>>” will change the year).

Go back to Freeway, select the text field again then open the Actions palette to see the options. You will see that this is very different to most other Freeway Actions in that you can enter “format tokens” to control how the form will process the date information.

The default settings in the Date Format field (which is %Y-%m-%d) will give you an “ISO format” date (such as 2011-12-25 if Christmas Day 2011 is chosen in the calendar), but you can add additional information or change how the date will appear after it is selected on the calendar (such as changing the day and date order for instance) by entering the format token you want to use from the list displayed on the page at ActionsForge. This is really for advanced users only, as it is normally only used to process the information entered in the text field so it can fed automatically into an online database.

Unless you want to make the text field active when the page is loaded, leave the Trigger Event popup set to the default of Click.