Web Development (2)

Day 2

I watched video 9 and video 10.

ID and Classes h4{ color: #141111; } p{ color: #1E1B1B; }

ID

ID can only be assigned to one HTML element within a page. Every ID should be unique. If a link is gentrated with the help of ID, it will take you to that particular section of that website.


Classes

A class can be assigned to many HTML elements within a page. The benefit is that you can change the style of all elements that are assigned to that particular class. More than one class can be assigned to a single element.


Represent in CSS

The ID is written like " #ID { Style goes here} .Class{Style goes here} ".


The code I used for this is:

The use of autoplay is to play the video automatically when the browser opens it. The use of loop is to play the video continuously. Muted will make your video mute (the user can unmute it). A poster is the same as a YouTube thumbnail (giving a poster to your video).



If preload="none", the browser will not load, until the user clicks on it. preload="metadata", the browser will load only metadata infromation. preload="auto", the audio will be automatically downloaded on browser. (preload is asked a lot in interviews.)


<circle cx="50" cy="50" r="40" stroke="black" strok-width="3" fill="green"


<'circle cx="50" cy="50" r="40" stroke="black" strok-width="3" fill="green"
You can also add svg from different file, by saving that file with .svg .


Quiz 2

It links website or even a YouTube video.