Home

Habib Khan

Lab 6

Tasks 1 - 10


Task 1

Display the current day and time


Task 2

Print the contents of the current window


Task 3

Find the area of a triangle where lengths of the three of its sides are 5, 6, 7





Task 4

Calculate days left until next Christmas


Task 5

Change the contents of a HTML P tag, from Hello World! to your name

Hello World!


Task 6

Set the attribute of a h1 tag to red

Red


Task 7

Change the image on a webpage to a different image and change the alt tag to the appropriate information

Night Time

A Night Time image, Reproduced from (pixaby, 2017)



Task 8

JavaScript function to get the values of First and Last name of a given form





Task 9

JavaScript function to add rows to a table

Cell Cell
Cell Cell


Task 9.1

Input rows and columns to create a table



Task 10

Calculate the volume of a sphere