display each month that has a friday 13th javascript code example
Example: display month friday 13th javascript year
function numberOfFridaythe13thsIn(jahr) {
var counter = 0;
for (i = 1; i <= 12; i++) {
var d = new Date(i + "/13/" + jahr);
if (d.getDay() == 5) {
counter++;
}
}
return counter;
}