HTML stands for "hypertext markup language." It's not a coding language. HTML is just hyperlinks and text that we "markup" by putting it inside elements. These elements are understood by the browser to know which things are links, text, images, or other items. Because HTML has meaningful names for those elements to make it more easily read and understood by humans, it's called "semantic" or "descriptive" markup.
head
element is made up of the start tag <head>
, the end tag </head>
, and everything between the tags)<a href="neocities.org">link to neocities<\a>
, the href
is an attribute and its value is "neocities.org".When you first make a new .html
file in Neocities, a basic page template is given to you that contains the most basic information for the browser to know when handling your page. We don't
<!DOCTYPE html>
: the very first thing in your web page to let the browser know to treat the file like HTML and not another markup language like XML or LaTeXhtml
: all of your HTML code goes inside the HTML tagshead
: not to be confused with a header
, the head
element contains more contextual information for the browser, like where to find stylesheets, what to name the window/tab, and what character set you'll use. inside the head
element, there are the following elements:
meta
: contains technical information about a pagetitle
: the name of the page that appears in the browser window or tablink
: gives the browser directions for finding things like stylesheets or script librariesbody
: the actual content of your website goes hereWebsites are made up of blocks and elements. The most common elements you'll use on your web page are:
div
: the all-purpose element. div
is short for "divider" and can be used for any kind of division/block/container you want
<div> <p>text goes here!<\p> <p>more text~<\p> <\div>
p
: the paragraph element. most text content is inside of p
tags.a
: the link element. text inside of an a
tag will be turned into a link. (if you're wondering where the a comes from, it stands for "anchor.")ul
and ol
: unordered and ordered list elements. these are bullet pointed lists. use ul
for regular bullet points and ol
for when you're using numbered bulletsli
: list items go in between your ul
and ol
tags. example:
<ul> <li>first thing<\li> <li>second thing<\li> <li>third thing<\li> <\ul>
h1, h2, h3, h4, h5, h6
: header elements. h1 is the biggest, intended for page titles, and h6 is the smallest.br
: the line break element. this is like hitting "enter" on your keyboard. you can write this element as <br></br>
, but it can be written as just <br />
img
: the image element. using the src
attribute, you can provide a link to an image. like the line break element, you can write it like <img src="image.png"></img>
, but it can be written as just <img src="image.png" />