Fix example redirecting_a_url. PEBKAC

This commit is contained in:
Roberto Abdelkader Martínez Pérez
2019-11-20 11:33:56 +01:00
parent 4c3fe37616
commit 850baf95f7
+12
View File
@@ -0,0 +1,12 @@
Redirecting a URL
=================
The HTTP protocol allows queries to a URL to be redirected to other URL.
We can do them in Kapow! with little effort:
In this example, we read the header ``User-Agent`` and feed it to the response:
.. code-block:: bash
kapow set /response/headers/Location 'http://example.org'
kapow set /response/status 301