FIND YOUR NEXT FEW LINES

Results for “options”

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

31 snippets foundClear filters
HTMLInput constraints

Allow several selected options

HTML: A multiple select exposes each selected option as a value with the same control name.

HTML✓ Tested
ReactForms & validation

Collect selected options from a multi-select

Collect selected options from a multi-select with a small React component and explicit browser behavior.

React✓ Tested
Bash ScriptsArguments & decisions

Parse a small set of long options

Bash Scripts: Use a loop and case statement to consume a value-bearing long option.

Bash Scripts✓ Tested
HTMLGetting Started

Provide a list of selectable options

HTML: Learn how to provide a list of selectable options in a complete browser example.

HTML✓ Tested
jQueryTraversal & selection

Read checked options

Collect checked checkbox values with jQuery map and get.

jQuery✓ Tested
jQueryForm serialization & state

Set several selected options

jQuery: Passing an array to val selects matching values in a multiple select.

jQuery✓ Tested
Docker / ComposeCompose service options

Add a fixed hostname mapping

Docker / Compose: extra_hosts adds an entry to the container’s hosts file.

Docker / Compose✓ Tested
Docker / ComposeCompose service options

Choose a service’s internal hostname

Docker / Compose: hostname controls the name reported inside the container.

Docker / Compose✓ Tested
Docker / ComposeCompose service options

Disable a service’s network interfaces

Docker / Compose: network_mode none leaves only the loopback interface.

Docker / Compose✓ Tested
Docker / ComposeCompose service options

Drop capabilities for a Compose service

Docker / Compose: cap_drop ALL removes optional Linux capabilities.

Docker / Compose✓ Tested
Docker / ComposeCompose service options

Enable an init process for a service

Docker / Compose: init adds a small PID 1 process to forward signals and reap children.

Docker / Compose✓ Tested
Docker / ComposeCompose service options

Give a read-only service writable scratch space

Docker / Compose: A tmpfs mount provides temporary storage independent of the root filesystem.

Docker / Compose✓ Tested