Category Archives: Jquery

JavaScript window.open only if the window does not already exist- Solution

var availableHeight = window.screen.availHeight;     var availableWidth = window.screen.availWidth;     var finalHeight;     var finalWidth;     for (H = 1; H < availableHeight; H++) {         finalHeight = H;     }     for (W = 1; W < availableWidth; W++) … Continue reading

Posted in Jquery | Leave a comment

Minimum allowed date and maximum allowed date in jQuery

this.RegisterCustomValidationMethod(MAXALLOWEDDATE_METHODNAME, “function(value, element, param) { var newDate = $(element).datepicker(‘getDate’); var checkDate = $.glob.format(newDate, ‘yyyyMMdd’); return this.optional(element) || parseInt(param) > parseInt(checkDate);});”); this.RegisterCustomValidationMethod(MINALLOWEDDATE_METHODNAME, “function(value, element, param) { var newDate = $(element).datepicker(‘getDate’); var checkDate = $.glob.format(newDate, ‘yyyyMMdd’); return this.optional(element) || parseInt(param) < parseInt(checkDate);});”);

Posted in Jquery | 1 Comment