SitePoint Sponsor

User Tag List

Results 1 to 4 of 4
  1. #1
    SitePoint Zealot GOPalmer's Avatar
    Join Date
    Jan 2009
    Location
    Wiltshire, UK
    Posts
    125
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Talking jQuery UI Datepicker - need help setting available days

    Hi Guys,

    I'm new to the jQuery lib and I'm currently working on a project that uses the UI datepicker for a booking system. I need the datepicker to show only days that are available for booking. Preferably id like to use json encoded array of days.

    Does anyone have an example of how this may be achieved?

    Best Regards, George

  2. #2
    SitePoint Wizard bronze trophy
    Join Date
    Jul 2008
    Posts
    5,757
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    This seems like the part of the api you would want to use
    http://docs.jquery.com/UI/Datepicker...-beforeShowDay

    I presume you would just test if the y/m/d held in the Date object is in your list, and return true or false.

  3. #3
    SitePoint Zealot GOPalmer's Avatar
    Join Date
    Jan 2009
    Location
    Wiltshire, UK
    Posts
    125
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Does anyone have an example? Im struggling a bit with this.

    Best Regards, George

  4. #4
    SitePoint Wizard bronze trophy
    Join Date
    Jul 2008
    Posts
    5,757
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •