ComputerScienceExpert

(11)

$18/per page/

About ComputerScienceExpert

Levels Tought:
Elementary,Middle School,High School,College,University,PHD

Expertise:
Applied Sciences,Calculus See all
Applied Sciences,Calculus,Chemistry,Computer Science,Environmental science,Information Systems,Science Hide all
Teaching Since: Apr 2017
Last Sign in: 103 Weeks Ago, 4 Days Ago
Questions Answered: 4870
Tutorials Posted: 4863

Education

  • MBA IT, Mater in Science and Technology
    Devry
    Jul-1996 - Jul-2000

Experience

  • Professor
    Devry University
    Mar-2010 - Oct-2016

Category > Programming Posted 24 May 2017 My Price 11.00

Extra 7-2 Develop the Calendar application

Extra 7-2 Develop the Calendar application

 

*Must use attached code*

*Image of example attached*

In this exercise, you’ll create an application that displays a calendar for the current month:

Note: To build this calendar, you’re going to need the getDay method of a Date object. This method returns the number of the day of the week (0 for Sunday, 1 for Monday, etc.).

  1. Open the HTML, CSS, and JavaScript files in this folder:

exercises_extrach07calendar

  1. In the HTML file, note the span element within the h1 element that will display the month name and year. Note also the table element that contains one row. To build the calendar, you need to add rows to this table after the row that it already contains.
  2. In the CSS file, note the rule set for the td elements of the table. The rules in this set will format the calendar as shown above.
  3. In the JavaScript file, note that four functions are supplied. The $ function. A getMonthText function that accepts the number for a month and returns the month name in text. The start of a getLastDayofMonth function. And the start of the onload event handler.
  4. Write the code for the getLastDayofMonth function. It should use the number passed in the currentMonth parameter to calculate and return the last day of the current month. See figure 7-11 for ideas on how to code this.
  5. In the onload event handler, write the code that gets and displays the name of the current month and the current year above the month table.
  6. In the onload event handler, write the code that loops through the days of the month to create the rows for the calendar. Remember to deal with the blank dates that can occur at the beginning of the first week and the end of the last week of the month. Use a tr element for each new row and td elements within the rows for the days of the months. To display the rows, add them to the innerHTML property of the calendar table, but remember that the new rows have to go after the row that’s in the HTML.

Attachments:

Answers

(11)
Status NEW Posted 24 May 2017 07:05 AM My Price 11.00

-----------

Not Rated(0)