Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Write a script that displays the current date and time, and welcomes the user with Good morning!, Good afternoon!, or Good evening!, depending on the

Write a script that displays the current date and time, and welcomes the user with Good morning!, Good afternoon!, or Good evening!, depending on the time of day.

You may find it useful to use the Date object, and to create variables to store elements of the date.

var dateObject= new Date(); var greeting = ; var curTime= ; var minuteValue = dateObject.getMinutes(); var hourValue = dateObject.getHours();

Note: You do not have to open a previous exercise to complete this exercise.

When you open your form for the first time, it should resemble this:

image text in transcribed

If you keep refreshing, the time will change.

Welcome to my Web Page Good morning! It is 9:59 AM on Thursday, November 2, 2017

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Case Studies In Business Data Bases

Authors: James Bradley

1st Edition

0030141346, 978-0030141348

More Books

Students also viewed these Databases questions