From 2a7c8574afa9e6b9d51a2a9b9cb25bd027ef3014 Mon Sep 17 00:00:00 2001 From: FireIsGood Date: Thu, 16 May 2024 16:45:12 -0700 Subject: [PATCH] fix: html format Fixes the button example not displaying correctly --- source/_posts/html.md | 591 ++++++++++++++++++++---------------------- 1 file changed, 287 insertions(+), 304 deletions(-) diff --git a/source/_posts/html.md b/source/_posts/html.md index bf8d3fc..5d4d7bd 100644 --- a/source/_posts/html.md +++ b/source/_posts/html.md @@ -3,33 +3,31 @@ title: HTML date: 2021-07-20 19:16:42 background: bg-[#cc5534] tags: - - web + - web categories: - - Programming + - Programming intro: | - This HTML quick reference cheat sheet lists the common HTML and HTML5 tags in readable layout. + This HTML quick reference cheat sheet lists the common HTML and HTML5 tags in readable layout. plugins: - - copyCode + - copyCode --- - -Getting Started ------------- +## Getting Started ### hello.html {.col-span-2 .row-span-2} ```html - + - - - - + + + + HTML5 Boilerplate - - + +

Hello world, hello CheatSheets.zip!

- + ``` @@ -46,59 +44,56 @@ Or try it out in the [jsfiddle](https://jsfiddle.net/Fechin/1e4wz20b/) --> ``` - ### Paragraph ```html

I'm from CheatSheets.zip

Share quick reference cheat sheet.

``` + See: [The Paragraph element](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/p) - - - ### HTML link -```html +```html CheatSheets Email Call Msg ``` + --- -| | | | -|---|----------|-----------------------------------------------------------------| -| | `href` | The URL that the hyperlink points to | -| | `rel` | Relationship of the linked URL | -| | `target` | Link target location:
`_self`, `_blank`, `_top`, `_parent` | +| | | | +| --- | -------- | --------------------------------------------------------------- | +| | `href` | The URL that the hyperlink points to | +| | `rel` | Relationship of the linked URL | +| | `target` | Link target location:
`_self`, `_blank`, `_top`, `_parent` | + {.left-text} See: [The \ Attributes](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#attributes) - - ### Image Tag ```html {.wrap} -Describe image here +Describe image here ``` + --- -| | | | -|---|-----------|------------------------------------------| -| | `src` | Required, Image location _(URL \| Path)_ | -| | `alt` | Describe of the image | -| | `width` | Width of the image | -| | `height` | Height of the image | -| | `loading` | How the browser should load | +| | | | +| --- | --------- | ---------------------------------------- | +| | `src` | Required, Image location _(URL \| Path)_ | +| | `alt` | Describe of the image | +| | `width` | Width of the image | +| | `height` | Height of the image | +| | `loading` | How the browser should load | + {.left-text} See: [The Image Embed element](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/img) - - ### Text Formatting Tags ```html @@ -119,23 +114,23 @@ See: [The Image Embed element](https://developer.mozilla.org/en-US/docs/Web/HTML
Text Block Quote
``` - ### Headings -```html -

This is Heading 1

-

This is Heading 2

-

This is Heading 3

-

This is Heading 4

-
This is Heading 5
-
This is Heading 6
-``` -You should only have one h1 on your page +```html +

This is Heading 1

+

This is Heading 2

+

This is Heading 3

+

This is Heading 4

+
This is Heading 5
+
This is Heading 6
+``` + +You should only have one h1 on your page ### Section Divisions | | | -|-----------------|--------------------------------------| +| --------------- | ------------------------------------ | | `
` | Division or Section of Page Content | | `` | Section of text within other content | | `

` | Paragraph of Text | @@ -144,19 +139,22 @@ You should only have one h1 on your page These are the tags used to divide your page up into sections - - ### Inline Frame {.row-span-2} + ```html {.wrap} - ``` + #### ↓ Preview + - See: [The Inline Frame element](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/iframe) - ### JavaScript in HTML ```html ``` - #### External JavaScript ```html - ... - - + ... + + ``` - ### CSS in HTML ```html ``` @@ -204,17 +198,15 @@ See: [The Inline Frame element](https://developer.mozilla.org/en-US/docs/Web/HTM ```html -... - + ... + ``` - - -HTML5 Tags -------------- +## HTML5 Tags ### Document + ```html
@@ -229,8 +221,8 @@ HTML5 Tags ``` - ### Header Navigation + ```html
``` - ### HTML5 Tags {.row-span-4} | | | -|------------------------------------------------------------------------------------|----------------------------------------| +| ---------------------------------------------------------------------------------- | -------------------------------------- | | [article](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/article) | Content that’s independent | | [aside](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/aside) | Secondary content | | [audio](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/audio) | Embeds a sound, or an audio stream | @@ -281,112 +272,112 @@ HTML5 Tags | [video](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/video) | Embeds video | | [wbr](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/wbr) | A line break opportunity | - ### HTML5 Video + ```html {.wrap} ``` + #### ↓ Preview + - ### HTML5 Audio + ```html {.wrap} - ### HTML5 Ruby + ```html {.wrap} - - 汉 (hàn) - 字 (zì) - + 汉 (hàn) 字 (zì) ``` + #### ↓ Preview + 汉 (hàn) 字 (zì) - ### HTML5 kdi + ```html
    -
  • User hrefs: 60 points
  • -
  • User jdoe: 80 points
  • -
  • User إيان: 90 points
  • +
  • User hrefs: 60 points
  • +
  • User jdoe: 80 points
  • +
  • User إيان: 90 points
``` + #### ↓ Preview +
  • User hrefs: 60 points
  • User jdoe: 80 points
  • User إيان: 90 points
- ### HTML5 progress + ```html ``` + - ### HTML5 mark + ```html

I Love CheatSheets.zip

``` +

I Love CheatSheets.zip

- -HTML Tables --------------- +## HTML Tables ### Table Example {.row-span-2} + ```html - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + +
nameage
Roberta39
Oliver25
nameage
Roberta39
Oliver25
``` - - ### HTML Table Tags {.row-span-2} | Tag | Description | -|-----------------------------------------------------------------------------------|----------------------------------| +| --------------------------------------------------------------------------------- | -------------------------------- | | [\](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/table) | Defines a table | | [\](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/tr) | Defines a row in a table | @@ -401,19 +392,17 @@ HTML Tables ### \
](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/th) | Defines a header cell in a table | | [\
Attributes | Attribute | Description | -|-----------|-----------------------------------------------| +| --------- | --------------------------------------------- | | `colspan` | Number of columns a cell should span | | `headers` | One or more header cells a cell is related to | | `rowspan` | Number of rows a cell should span | See: [td\#Attributes](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/td#attributes) - - ### \ Attributes | Attribute | Description | -|----------------------------------------------------------------------------------|-----------------------------------------------| +| -------------------------------------------------------------------------------- | --------------------------------------------- | | `colspan` | Number of columns a cell should span | | `headers` | One or more header cells a cell is related to | | `rowspan` | Number of rows a cell should span | @@ -422,71 +411,66 @@ See: [td\#Attributes](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/ See: [th\#Attributes](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/th#attributes) - - -HTML Lists --------------- - +## HTML Lists ### Unordered list + ```html
    -
  • I'm an item
  • -
  • I'm another item
  • -
  • I'm another item
  • +
  • I'm an item
  • +
  • I'm another item
  • +
  • I'm another item
``` -See: [The Unordered List element](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/ul) +See: [The Unordered List element](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/ul) ### Ordered list ```html
    -
  1. I'm the first item
  2. -
  3. I'm the second item
  4. -
  5. I'm the third item
  6. +
  7. I'm the first item
  8. +
  9. I'm the second item
  10. +
  11. I'm the third item
``` -See: [The Ordered List element](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/ol) +See: [The Ordered List element](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/ol) ### Definition list ```html
-
A Term
-
Definition of a term
-
Another Term
-
Definition of another term
+
A Term
+
Definition of a term
+
Another Term
+
Definition of another term
``` + See: [The Description List element](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/dl) - - - -HTML Forms ------------ - +## HTML Forms ### Form tags {.row-span-2} + ```html
- -
+ +
- -
- -
- + +
+ +
+
``` #### ↓ Preview +
@@ -500,13 +484,12 @@ HTML Forms
- The HTML `
` element is used to collect and send information to an external source. - ### Form Attribute + | Attribute | Description | -|------------|-----------------------------------------------------------------------------------------------------| +| ---------- | --------------------------------------------------------------------------------------------------- | | `name` | Name of form for scripting | | `action` | URL of form script | | `method` | HTTP method, `POST` / `GET` _(default)_ | @@ -514,35 +497,34 @@ The HTML `` element is used to collect and send information to an external | `onsubmit` | Runs when the form was submit | | `onreset` | Runs when the form was reset | - - - - ### Label tags + ```html -