Results for “url”
Small, practical examples. Search by task or narrow things down below.
Send a JSON HTTP response
Send a JSON HTTP response using a complete Go program with explicit sample inputs.
Go✓ Tested
Set and retrieve an HTTP header
Set and retrieve an HTTP header using a complete Go program with explicit sample inputs.
Go✓ Tested
Split text on several separator characters
JavaScript: A regex character class can recognize alternative simple delimiters.
JavaScript✓ Tested
Split text on several separator characters
TypeScript: A regex character class can recognize alternative simple delimiters.
TypeScript✓ Tested
Test an HTTP handler without a server
Test an HTTP handler without a server using a complete Go program with explicit sample inputs.
Go✓ Tested
Validate a whole ASCII identifier
JavaScript: Use an anchored expression without the multiline flag and reject a trailing line break explicitly.
JavaScript✓ Tested
Validate a whole ASCII identifier
TypeScript: Use an anchored expression without the multiline flag and reject a trailing line break explicitly.
TypeScript✓ Tested
Inspect a parsed URI
C#: Use Uri properties instead of splitting URL strings manually.
C#✓ Tested
Inspect a URI through typed properties
PowerShell: The Uri class separates URL components without manual string splitting.
PowerShell✓ Tested
Inspect components of a URI
Java: Use URI parsing instead of splitting a URL at punctuation manually.
Java✓ Tested
Offer a downloadable text file
HTML: The download attribute supplies a filename for this same-document data URL.
HTML✓ Tested