@@ -43,7 +43,7 @@ You can check the HTTP method that this request represents with the ``method()``
4343
4444.. literalinclude :: incomingrequest/005.php
4545
46- By default, the method is returned as a lower-case string (i.e., 'get', 'post', etc). You can get an
46+ By default, the method is returned as a lower-case string (i.e., `` 'get' ``, `` 'post' `` , etc). You can get an
4747uppercase version by wrapping the call in ``strtoupper() ``::
4848
4949 // Returns 'GET'
@@ -56,9 +56,9 @@ You can also check if the request was made through and HTTPS connection with the
5656Retrieving Input
5757----------------
5858
59- You can retrieve input from $_SERVER, $_GET, $_POST, and $_ENV through the Request object.
59+ You can retrieve input from `` $_SERVER ``, `` $_GET ``, `` $_POST `` , and `` $_ENV `` through the Request object.
6060The data is not automatically filtered and returns the raw input data as passed in the request. The main
61- advantages to using these methods instead of accessing them directly ($_POST['something']), is that they
61+ advantages to using these methods instead of accessing them directly (`` $_POST['something'] `` ), is that they
6262will return null if the item doesn't exist, and you can have the data filtered. This lets you conveniently
6363use data without having to test whether an item exists first. In other words, normally you might do something
6464like this:
@@ -69,23 +69,23 @@ With CodeIgniter's built-in methods you can simply do this:
6969
7070.. literalinclude :: incomingrequest/008.php
7171
72- The ``getVar() `` method will pull from $_REQUEST, so will return any data from $_GET, $POST, or $_COOKIE. While this
72+ The ``getVar() `` method will pull from `` $_REQUEST `` , so will return any data from `` $_GET ``, `` $POST `` , or `` $_COOKIE `` . While this
7373is convenient, you will often need to use a more specific method, like:
7474
7575* ``$request->getGet() ``
7676* ``$request->getPost() ``
7777* ``$request->getServer() ``
7878* ``$request->getCookie() ``
7979
80- In addition, there are a few utility methods for retrieving information from either $_GET or $_POST, while
80+ In addition, there are a few utility methods for retrieving information from either `` $_GET `` or `` $_POST `` , while
8181maintaining the ability to control the order you look for it:
8282
83- * ``$request->getPostGet() `` - checks $_POST first, then $_GET
84- * ``$request->getGetPost() `` - checks $_GET first, then $_POST
83+ * ``$request->getPostGet() `` - checks `` $_POST `` first, then `` $_GET ``
84+ * ``$request->getGetPost() `` - checks `` $_GET `` first, then `` $_POST ``
8585
8686**Getting JSON data **
8787
88- You can grab the contents of php://input as a JSON stream with ``getJSON() ``.
88+ You can grab the contents of `` php://input `` as a JSON stream with ``getJSON() ``.
8989
9090.. note :: This has no way of checking if the incoming data is valid JSON or not, you should only use this
9191 method if you know that you're expecting JSON.
0 commit comments