Code Coverage |
||||||||||
Classes and Traits |
Functions and Methods |
Lines |
||||||||
| Total | |
0.00% |
0 / 1 |
|
0.00% |
0 / 1 |
CRAP | |
0.00% |
0 / 10 |
| Index | |
0.00% |
0 / 1 |
|
0.00% |
0 / 1 |
6.00 | |
0.00% |
0 / 10 |
| getIndexPage | |
0.00% |
0 / 1 |
6.00 | |
0.00% |
0 / 10 |
|||
| <?php | |
| namespace Luxian\Controller; | |
| use Luxian\Http\Response; | |
| class Index extends ControllerBase | |
| { | |
| public function getIndexPage(): Response | |
| { | |
| $html = ''; | |
| $debug = [ | |
| '_POST' => $this->request->getPost(), | |
| '_GET' => $this->request->getQuery(), | |
| '_SERVER' => $this->request->getServerInfo(), | |
| ]; | |
| foreach ($debug as $variable_name => $value) { | |
| $html .= '<h1>' . htmlentities($variable_name) . '</h1>'; | |
| $html .= '<pre>' . var_export($value, true) . '</pre>'; | |
| } | |
| $response = new Response(); | |
| $response->setBody($html); | |
| return $response; | |
| } | |
| } |