how to write a program that displays a message “It’s Fun day” if it's Saturday or Sunday today in javascript
var currentDate = new Date();
currentDate.toString;
var b = currentDate.toString();
var c = b.slice(0,3);
if (c === "Sat"){
document.write("It's Fun Day")
}else if(c === "Sun"){
document.write("It's Fun Day")
}else if(c === "Mon"){
document.write()
}else if(c === "Tue"){
document.write()
}else if(c === "Wed"){
document.write()
}else if(c === "Thr"){
document.write()
}else if(c === "Fri"){
document.write()
}
Also in JavaScript:
- ajax stand for
- npm font awesome vue
- js add array items to array
- React Components
- angular redirect to external url
- mongodb nodejs connect localhost
- aws lambda function setup for node js
- javascript prototype inheritance example
- redirect with javascript
- concantene number in js
- edit onclick event
- react component key prop
- daysinmonth javascript
- detecting change in animated value react native
- console in jsfiddle site:stackoverflow.com
- express multer example
- import leaflet js
- js split last occurence
- javascript urlsearchparams to object
- node send file
- how to send query parameters in url vuejs
- mongoose update array in object
- js create element
- iterate table in jquery