FIND YOUR NEXT FEW LINES

Results for “position”

Small, practical examples. Search by task or narrow things down below.

81 snippets foundClear filters
CSSPositioning & stacking

Position a badge relative to its container

CSS: A positioned ancestor establishes the containing block for an absolutely positioned child.

CSS✓ Tested
CSSPositioning & stacking

Position an item from the writing direction’s start edge

CSS: Logical insets follow direction, so inline-start is the right side in this RTL container.

CSS✓ Tested
Bash ScriptsGetting Started

Read positional parameters in a function

Bash Scripts: Read positional parameters in a function with a small standalone Bash program.

Bash Scripts✓ Tested
jQueryInsertion & wrapping

Replace an element while preserving its position

jQuery: replaceWith swaps an entire node.

jQuery✓ Tested
CFile positioning & lifecycle

Replace bytes at a known position in a binary file

C: Open in update mode and seek before writing a fixed-size replacement.

C✓ Tested
C++Sequence algorithms

Rotate a sequence around a selected position

C++: rotate places the element at the middle iterator first while preserving the two segment orders.

C++✓ Tested
jQueryTraversal & selection

Select an element by zero-based position

jQuery: eq returns a jQuery collection containing the selected index.

jQuery✓ Tested
SQL ServerDates & text

Split delimited text with positions

Retain original order with STRING_SPLIT ordinals.

STRING_SPLIT✓ Tested
Bash ScriptsArguments & decisions

Validate the number of positional arguments

Bash Scripts: Use the argument count to enforce a simple command-line contract.

Bash Scripts✓ Tested
CSSVisual treatment & accessibility

Align an image within its content box

CSS: Object-position places the rendered object when fitting leaves spare space or crops an edge.

CSS✓ Tested
Bash ScriptsFunction scope & composition

Capture output while handling a failed command

Bash Scripts: An assignment inherits the status of its command substitution, allowing both output and status to be handled.

Bash Scripts✓ Tested
CSSPositioning & stacking

Center a fixed-size absolute child with auto margins

CSS: An all-zero inset plus auto margins distributes the available space around the child.

CSS✓ Tested