Results for “Refs & DOM interaction”
Small, practical examples. Search by task or narrow things down below.
Write an ordered set of steps
HTML: Learn how to write an ordered set of steps in a complete browser example.
HTML✓ Tested
Write an unordered list
HTML: Learn how to write an unordered list in a complete browser example.
HTML✓ Tested
Write subscripts and superscripts in ordinary text
HTML: Sub and sup position short annotations such as formula indices and exponents.
HTML✓ Tested
Add a multiline text field
Set a maximum length and visible rows on a labeled HTML textarea.
HTML✓ Tested
Add semantic page landmarks
Identify the header, navigation, main content and footer with semantic HTML.
HTML✓ Tested
Append a list item
Build a jQuery element with text and append it safely.
jQuery✓ Tested
Associate a label with an input
Give an HTML text input an accessible name using for and id.
HTML✓ Tested
Clear an element
Remove child content while keeping the jQuery-selected container.
jQuery✓ Tested
Clip content that exceeds a fixed-height box
CSS: Overflow hidden clips the painted content while the full content remains in the DOM.
CSS✓ Tested
Create a native disclosure
Use details and summary to show optional HTML content without JavaScript.
HTML✓ Tested
Create an ordered list
Represent a sequence of steps using an HTML ordered list.
HTML✓ Tested
Declare document language and encoding
Set the HTML language, UTF-8 encoding and viewport for accessible responsive content.
HTML✓ Tested