for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Anax\Ip3;
use Anax\Commons\ContainerInjectableInterface;
use Anax\Commons\ContainerInjectableTrait;
class CheckjsonController3 implements ContainerInjectableInterface
{
use ContainerInjectableTrait;
public function initialize()
$this->IpController = new Validera3();
IpController
}
public function indexAction() : array
$ipController = new Validera3();
$ipController
$ipadress = $this->di->request->getGet("ipjson");
request
Psr\Container\ContainerInterface
instanceof
$weather = $this->di->get("validera3");
$json = [
"Stad" => $ipadress,
"validerbar" => $weather->check($ipadress),
"weatherForecast" => $weather->getWeather($ipadress)["weatherForecast"],
"weatherHistory" => $weather->getWeather($ipadress)["weatherHistory"],
];
return [$json];