htmlspecialchars with the flags spelled out, because the defaults have changed between versions.
All Snippets
A collection of code, notes, and solutions.
password_hash picks the algorithm and the salt. Never store anything a hash function can reverse.
tally does the counting; group_by keeps the members when you need them.
&. stops at nil; fetch raises rather than returning nil when a key is genuinely required.
Prints the subject, issuer and validity dates without opening a browser.
Splits DNS, connect, TLS and first byte apart, which tells you which one is actually slow.
Traces a redirect chain to its destination without downloading the body.
dig with +short strips everything but the answer.
Forwards a local port through a bastion so a client can connect as if the database were local.
Adds the third field of every line and prints the total, ignoring anything non-numeric.
ripgrep finds the files, sed edits them in place. The dry run first is not optional.
jq for the common cases: reformat, pick a path, filter an array, and reshape.