Dev Shed Forums - JavaScript Development http://forums.devshed.com/ JavaScript Development forum discussing JavaScript and DHTML, AJAX, and issues such as coding cross-browser JavaScript. en Thu, 22 Nov 2018 09:12:38 GMT vBulletin 60 http://forums.devshed.com/images/misc/rss.png Dev Shed Forums - JavaScript Development http://forums.devshed.com/ <![CDATA[Limit available days for jQuery's Datepicker]]> http://forums.devshed.com/javascript-development/981198-limit-available-days-jquerys-datepicker-new-post.html Wed, 21 Nov 2018 14:24:39 GMT Well, I've seen notes about beforeShowDay:, but not too sure on the handing my PHP array over, or maybe a way to build the same setup on jQuery's side.
PHP Code:

$arr[0] = [FALSEFALSETRUEFALSEFALSETRUEFALSE];
$arr[1] = [FALSETRUEFALSEFALSEFALSEFALSEFALSE];
$arr[2] = [TRUEFALSEFALSETRUEFALSEFALSEFALSE];
$arr[3] = [FALSEFALSEFALSEFALSETRUEFALSETRUE]; 

This defines the work days in a 4-week structure. The project is a "Request Off" type page. I simply want Datepicker to limit the selectable dates in the same format, but am apparently overlooking the setup.

My initial thought was to have PHP build it since that's where I started, but the structure is the same, so would there be a better option to have jQuery apply such an available/selectable setup? The only option I would need to offer would be an offset which simply builds it in 4 different displays and just having the week being the offset. ]]>
JavaScript Development Triple_Nothing http://forums.devshed.com/javascript-development-115/limit-available-days-jquerys-datepicker-981198.html