{fragment 'name'} marks a part of the page. A normal request renders it in
place, as if the tag were not there - which is what the examples below show. A request that
names it - ?orders&padFragment=order-list, or a page whose PHP sets
$padFragmentOnly = 'order-list' - gets that fragment's rendering and nothing
else: the page renders up to the end of the fragment, which is then the whole response, bare
and untidied; the rest of the page does not render. The first fragment of that name to finish
is the one sent.
This is the server side of partial page updates: htmx
(hx-get="?orders&padFragment=order-list") and
{ajax 'orders', fragment='order-list'}. An htmx request
that names no fragment asks for the one called like its target: with
hx-target="#order-list" htmx sends HX-Target: order-list, and a page
with a fragment of that name answers it alone. A page without one renders whole.
Keep conditions inside the fragment rather than around it: a fragment asked for that never rendered is an error under the strict check, and an empty 404 otherwise. A fragment without a name, or one that never closes, is an error under the strict check. The page cache never stores a fragment the PHP chose, since its key is the address.