Text Markups

Demonstrates various text markups

Abbreviations or acronyms using abbr

The WWW is teeming with abbreviations.

Marking up text as the source of a working title using cite

According to the book HTML and CSS—The Comprehensive Handbook it should read:

In HTML 4.01, this element was also used for short quotations. In new HTML, the semantic meaning has been converted and should now only be used for working titles.

Computer code representation using code

The code element does not contain any attributes.

A preformatted text with pre

Here is a source code snippet of a C program:

#include <stdio.h>
                
int main(void)
{
    puts("Hello World!");
    return 0;
}
Listing 1: Hello World in C

Keyboard input with kbd and program output with samp

You can use Strg + A to mark up the entire text.

term#1> gcc -o Wall hello hello.c
term#1> ./hello
Hello World!
term#1>

Marking up a text as a definition using dfn

A smartphone—as opposed to a cell phone—provides more computer functionality and better connectivity.

Marking up text as a variable using var

The radius r is equal to half the diameter d.

Changing the text direction using bdo and bdi

Never odd or even

שלום

السلام عليكم: 1 (as-salaam alaykum)

שלום: 2 (shalom)

Howdy: 3 (greetings in the rural Southern United States)

Emphasizing text using em, strong, i, and b

Bear! Who the hell is this Bear!

Caution! Bear could be standing behind you!

Delivery date in summer 2023

Highlighting text using mark

In 2021, profits have increased by 100 percent.

Here is a source code snippet of a C program:

#include <stdio.h>

int main(void)
{
    puts("Hello world!");
    return 0;
}

Placing text between quotes using q

Wolf asked: Bear! Who the hell is this Bear!

Fox replied: Caution! Bear could be standing behind you!

Underlining or crossing out text using s and u

You can place a text in the middle with <center> or the CSS feature text-align and the value center.

我来自德国。= I am from Germany.

Also, spellig errors can be marked with it.

Marking changes of text using del und ins

The singer performs on 1/1/2024 in the concert hall!

The concert was canceled, because the singer is sick!

Displaying text as superscript or subscript using sub und sup

[1] Reaction scheme: 2 H2O → 2 H2 + O2

[2] Calculate circular area: A = π * r 2

[1] = http://wikipedia.org/wiki/Water
[2] = http://wikipedia.org/wiki/Circle

Marking dates and times using time

We met on my at Bear’s place.

We met on my at Bear’s place at 8pm.

We met on at Bear’s place at

On every I got flowers.

The concert in the photo was recorded sometime in this year.

The rock festival lasted .

Small print with small

© John Doe;

The shipment can be delivered in . (Due to high demand it can also take longer (+1 day)).

ruby, rt und rp for annotations about the pronunciation

LOL (Laugh Out Loud)

More information: http://de.wikipedia.org/wiki/Ruby_Annotation

Grouping ranges of individual text passages using span

Current temperature 64 F

Formatting with CSS and the span element.