from the end if there's no last row
output += '<\/table><\/td><\/tr>';
}
if (ppcNN6) {
output += '<\/table><\/form>';
}
else {
output += '<\/form><\/table>';
}
curDate.setDate(1);
curDate.setMonth(startMonth);
curDate.setFullYear(startYear);
return output;
}
function getDayLink(linkDay,isGreyDate,linkMonth,linkYear) {
var templink;
if (!(IsUsingMinMax)) {
if (isGreyDate) {
templink='' + linkDay + '<\/td>';
}
else {
if (isDayToday(linkDay)) {
templink=' | ' + '' + linkDay + '<\/a>' +'<\/td>';
}
else {
templink=' | ' + '' + linkDay + '<\/a>' +'<\/td>';
}
}
}
else {
if (isDayValid(linkDay,linkMonth,linkYear)) {
if (isGreyDate){
templink=' | ' + linkDay + '<\/td>';
}
else {
if (isDayToday(linkDay)) {
templink=' | ' + '' + linkDay + '<\/a>' +'<\/td>';
}
else {
templink=' | ' + '' + linkDay + '<\/a>' +'<\/td>';
}
}
}
else {
templink=' | '+ linkDay + '<\/td>';
}
}
return templink;
}
function isDayToday(isDay) {
if ((curDate.getFullYear() == todayDate.getFullYear()) && (curDate.getMonth() == todayDate.getMonth()) && (isDay == todayDate.getDate())) {
return true;
}
else {
return false;
}
}
function isDayValid(validDay, validMonth, validYear){
curDate.setDate(validDay);
curDate.setMonth(validMonth);
curDate.setFullYear(validYear);
if ((curDate>=minDate) && (curDate<=maxDate)) {
return true;
}
else {
return false;
}
}
function padout(number) { return (number < 10) ? '0' + number : number; }
function clearDay() {
eval('document.' + calfrmName + '.day.value = \'\'');
eval('document.' + calfrmName + '.month.value = \'\'');
eval('document.' + calfrmName + '.year.value = \'\'');
hideCalendar();
if (FuncsToRun!=null)
eval(FuncsToRun);
}
function changeDay(whatDay) {
curDate.setDate(whatDay);
// eval('document.' + calfrmName + '.' + curDateBox + '.value = "'+ padout(curDate.getDate()) + '-' + padout(curDate.getMonth()+1) + '-' + curDate.getFullYear() + '"');
eval('document.' + calfrmName + '.day.value = "'+ padout(curDate.getDate()) + '"');
eval('document.' + calfrmName + '.month.value = "'+ padout(curDate.getMonth()+1) + '"');
eval('document.' + calfrmName + '.year.value = "'+ curDate.getFullYear() + '"');
hideCalendar();
if (FuncsToRun!=null)
eval(FuncsToRun);
}
function scrollMonth(amount) {
var monthCheck;
var yearCheck;
if (ppcIE) {
monthCheck = document.forms["Cal"].cboMonth.selectedIndex + amount;
}
else if (ppcNN) {
monthCheck = document.popupcalendar.document.forms["Cal"].cboMonth.selectedIndex + amount;
}
if (monthCheck < 0) {
yearCheck = curDate.getFullYear() - 1;
if ( yearCheck < minYearList ) {
yearCheck = minYearList;
monthCheck = 0;
}
else {
monthCheck = 11;
}
curDate.setFullYear(yearCheck);
}
else if (monthCheck >11) {
yearCheck = curDate.getFullYear() + 1;
if ( yearCheck > maxYearList-1 ) {
yearCheck = maxYearList-1;
monthCheck = 11;
}
else {
monthCheck = 0;
}
curDate.setFullYear(yearCheck);
}
if (ppcIE) {
curDate.setMonth(document.forms["Cal"].cboMonth.options[monthCheck].value);
}
else if (ppcNN) {
curDate.setMonth(document.popupcalendar.document.forms["Cal"].cboMonth.options[monthCheck].value );
}
domlay('popupcalendar',1,ppcX,ppcY,Calendar(curDate.getMonth(),curDate.getFullYear()));
}
function changeMonth() {
if (ppcIE) {
curDate.setMonth(document.forms["Cal"].cboMonth.options[document.forms["Cal"].cboMonth.selectedIndex].value);
domlay('popupcalendar',1,ppcX,ppcY,Calendar(curDate.getMonth(),curDate.getFullYear()));
}
else if (ppcNN) {
curDate.setMonth(document.popupcalendar.document.forms["Cal"].cboMonth.options[document.popupcalendar.document.forms["Cal"].cboMonth.selectedIndex].value);
domlay('popupcalendar',1,ppcX,ppcY,Calendar(curDate.getMonth(),curDate.getFullYear()));
}
}
function changeYear() {
if (ppcIE) {
curDate.setFullYear(document.forms["Cal"].cboYear.options[document.forms["Cal"].cboYear.selectedIndex].value);
domlay('popupcalendar',1,ppcX,ppcY,Calendar(curDate.getMonth(),curDate.getFullYear()));
}
else if (ppcNN) {
curDate.setFullYear(document.popupcalendar.document.forms["Cal"].cboYear.options[document.popupcalendar.document.forms["Cal"].cboYear.selectedIndex].value);
domlay('popupcalendar',1,ppcX,ppcY,Calendar(curDate.getMonth(),curDate.getFullYear()));
}
}
function makeArray0() {
for (i = 0; i |