HTML #2 ~ HTML Properties

HJ's Coding Journey·2021년 8월 7일

[Learn] HTML/CSS

목록 보기

Text Elements

When writing content in HTML, we usually start with a heading to create titles. We use the h1 tag to create the first heading in HTML. We can choose the size of our heading through numbers. 'h1' has the largest size and goes all the way to 'h6' with the smallest size.

Additionally, we can write paragraphs add full text content. Usually these paragraphs would go under headings. In order to use paragraphs, we use the p tag.

// headings
// paragraph


Developers use Lists to create an ordered format of texts. There are two types of lists we can use in HTML. Ordered List and Unordered List. Ordered list is numbered, while unordered list uses plain dots.

// Ordered List
  <li>Main Course</li>
// Unordered List
  <li>Cold Drinks</li>
  <li>Hot Drinks</li>

Images and Attributes

We add images in HTML using the img tag. Unlike other tags, the image element does not have a closing tag. We simply end with a self-closing tag (/>). Starting with image elements, we can add attributes. An attribute is used to provide additional information about HTML elements. For images, we use the src attribute to link the source of where the image came from. This will help the user know what the image is about in case it does not show on the browser.

<img src="img.jpg" alt="img name" />

Hyperlinks in HTML are what enables the internet to be a worldwide web. Links either point to other pages within their own website or pages that are outside in another website. When creating a link, we use the a tag. We also use an attribute known as href in order to specify the url of the designated website. We also write a small description between the opening and closing tag to create a title for the link. We can also use a target attribute and write _blank to open a completely new page to that url.

<a href="">Website Link</a>

HTML Page Structure

Developers are encouraged to always write code by semantically structuring their HTML page. For this, there are various semantic tags.

// For navigating links
// For structuring headers and texts
// For creating footer information
Improving Everyday

1개의 댓글

2022년 12월 15일

HTML is a markup language used to create web pages. Here you check this landscape design wellington and get more new ways to design ideas. HTML codes tell your browser which elements to display, where on the page they will go, and how they may interact with other elements on the page. It's essential that you know HTML in order to create a website or blog. This tutorial is going to cover all of the HTML properties.

답글 달기