(a)
To create a Date object that contains the date May 19, 2018 at 9:31:27 a.m and store it in the variable named thisDay.
(b)
To declare two variable named localDate and localTime. The localDate variable contains the text of the date from the thisDay variable using local conventions. The localTime variable contains the text of the time stored in the thisDay variable using local conventions.
(c)
To write the code for datetime where date and time are the values of the localDate and localTime variables, Within the inner HTML of the page element with the ID currentTime.
(d)
To Call the nextJuly4() function using thisDay as the parameter value and store the date returned by the function in the j4Date variable..
(e)
To apply the setHours() method to the j4Date variable to change the hours value to 9 p.m..
(f)
To create variables named days, hrs, mins, and secs containing the days, hours, minutes, and seconds until 9 p.m. on the next 4th of July.
(g)
To Change the text content of the elements with the IDs “dLeft”, “hLeft”, “mLeft”, and “sLeft” to the values of the days, hrs, mins, and secs variables rounded down to the next lowest integer.
Trending nowThis is a popular solution!
Chapter 9 Solutions
New Perspectives on HTML5, CSS3, and JavaScript
- Please create using C# The sales tax rate is 5.5%. Rename all text boxes, using a 2 after their names as in:txtNumScoops2, txtUnitPrice2, btnCalculate2, etc.10. Delete the Discount Code label and the Discount Code text box11. Add a group box from your toolbox, change the text property to be Discount Code12. Click on the group box, and then click the radio button object in the toolbox13. Change the text property for the radio button to Discount 20%, rename (ID property)to radDiscount2014. Copy the radio button two more times15. Rename them to be radDiscount10 and radDiscount0 and change the text properties tobe Discount 10%, Discount 0%/16. Do the same calculations as the top objects, however modify your code to use theradio button to determine which discount option to implementa. The code to check if a radio button has been selected would be:if (radDiscount20.Checked) //this implies the first button has been selected17. To clear a radio button the code would be:radDiscount20.Checked =…arrow_forwardReturn to the links.js file in your editor and create an event listener for the load event that runs an anonymous function. Within the anonymous function, create the allSelect variable referencing all select elements nested within the govLinks form. Loop through the allSelect object collection and for each selection list in the collection create an anonymous function for the onchange event. Within this anonymous function, use the href property of the location object to change the page shown in the browser window to the value of the target of the event object that initiated the onchange event. Document your commands with JavaScript comments.arrow_forwardUsing the Pandas DataFrame isnull() function, convert our forestfire_df to a boolean DataFrame (here true indicates an element is a missing value) (docs). Put the result in the forestfire_isnull variable. # TODO 1.1 forestfire_isnull = display(forestfire_isnull) todo_check([ (forestfire_isnull.shape == (517,13),"forestfire_isnull shape does not match (517, 13)"), (np.all(forestfire_isnull.iloc[10:20,0].values == np.array([False,False,False,False,False,False,False,False,False,False])),"The values of forestfire_isnull were incorrect!") ])arrow_forward
- 8. In the list of interest rates (range A13:A25), create a Conditional Formatting Highlight Cells Rule to highlight the listed rate that matches the rate for the Charles Street property (cell D4) in Light Red Fill with Dark Red Text.arrow_forwardHTML/JAVASCRIPT Take the attached application and modify the second function so that if the user enters ANY name , for example Lawrence Michael Wolk into the input box next to the second function, the span output will be L.Michael.W. So if the name were instead Michael William Jackson, the output will be M.Wiiliam.J. (See output png attachments) CISC_2350_CH_8_pp300_converter_asplithw.html <html> <head> <script src="split.js" defer></script> </head> <body> <h1>Name Converter</h1> <p>Type your name:</p> <div> <input id="name" type="text" size="24" /> </br> <span id ="span1">second output goes here</span></br> <button id="but0">Convert to last, First</button> </br></br> <button id="buta"> Convert From Name MI. Lname to FI.MI.LI.</button></br> <input id ="name1" type ="text" size ="24"/> <span id= "span2">Third output goes here</span>…arrow_forwardEvent Listeners Go to the co_cart.js file in your editor. Directly below the initial comment section, add an event listener for the window load event that does the following when the page is loaded: Runs the calcCart() function. Add an event handler to the modelQty field in the cart form that runs the calcCart() function when the field value is changed. A for loop that loops through every option in the group of shipping option buttons, adding an event handler to run the calcCart() function when each option button is clicked. JavaScript Functions Create the calcCart() function to calculate the cost of the customer’s order using field values in the cart form. Within the calcCart() function do the following: Create a variable named orderCost that is equal to the cost of the espresso machine stored in the modelCost field multiplied by the quantity of machines ordered as stored in the modelQty field. Display the value of the orderCost variable in the orderCost field, formatted as U.S.…arrow_forward
- New Perspectives on HTML5, CSS3, and JavaScriptComputer ScienceISBN:9781305503922Author:Patrick M. CareyPublisher:Cengage LearningNp Ms Office 365/Excel 2016 I NtermedComputer ScienceISBN:9781337508841Author:CareyPublisher:CengageProgramming with Microsoft Visual Basic 2017Computer ScienceISBN:9781337102124Author:Diane ZakPublisher:Cengage Learning