method filters demo

received GET method
filters.htex source file, using htmx library to generate HTTP requests with other methods:
<!layout /.includes/layout.htex>
<article>
  <h2>method filters demo</h2>
  <!method get>received GET method
  <!method get ok>with ok query
  <!method get id>with id (id=<!query id>)
    <!method get id=1>(one)
    <!method get id=2>(two)
  <!method any>
  <hr>
  <ul>
    <li><a href="#" hx-target="body" hx-get=".">get</a></li>
    <li><a href="#" hx-target="body" hx-get="?ok">get?ok</a></li>
    <li>
      <a href="#" hx-target="body" hx-get="?id">get?id</a> /
      <a href="#" hx-target="body" hx-get="?id=1">get?id=1</a> /
      <a href="#" hx-target="body" hx-get="?id=2">get?id=2</a>
    </li>
  </ul>
</article>
<article>
  <code>filters.htex</code> source file, using <a href="https://htmx.org">htmx</a> library to generate HTTP requests with other methods:
  <pre><code class="language-html"><!include-escaped filters.htex></code></pre>
</article>
htex - hypertext extruder

method layouts demo

here GET is handled with a default layout, and POST returns just a regular message (without layout):

reset (GET) // click here to POST

result: [text will be received here]

method-layouts.htex source file, using htmx library to generate a POST HTTP request:
<!method get>
  <!layout /.includes/layout.htex>
  <article>
    <h2>method layouts demo</h2>
    <p>here GET is handled with a default layout, and POST returns just a regular message (without layout):
    <p><a href=".">reset (GET)</a> // <a href="#" hx-target="#result" hx-post=".">click here to POST</a></p>
    <p>result: <code id="result">[text will be received here]</code></p>
  </article>
  <article>
    <code>method-layouts.htex</code> source file, using <a href="https://htmx.org">htmx</a> library to generate a POST HTTP request:
    <pre><code class="language-html"><!include-escaped method-layouts.htex></code></pre>
  </article>
<!method post>
  <strong>response from POST method (without layout)</strong>