Home Files
Adminer
Execute Command
PHP Eval
Symlink
File Upload
Owner :
www-data
PHP Version
8.1.8
Disk Space
203.89 GB
Server Addr
171.9.3.2
Your IP
171.9.3.1
Edit File
File:
<?php class SalvarLog { var $Acao = "NULL"; var $Tela = "NULL"; var $Registro = "NULL"; var $Usuario = "NULL"; var $Tipo = "W"; var $Tabela = "NULL"; var $IdRegistro = 0; var $Campo = "NULL"; var $Grupo = "NULL"; public function ArrayLog () { $arrayValue[':Acao'] = $this->Acao; $arrayValue[':Tela'] = $this->Tela; $arrayValue[':Registro'] = $this->Registro; $arrayValue[':Usuario'] = $this->Usuario; $arrayValue[':Tipo'] = $this->Tipo; $arrayValue[':Tabela'] = $this->Tabela; $arrayValue[':IdRegistro'] = $this->IdRegistro; $arrayValue[':Campo'] = $this->Campo; $arrayValue[':Computador'] = $this->get_client_ip_log(); $arrayValue[':Grupo'] = $this->Grupo; return $arrayValue; } public function get_client_ip_log() { $ipaddress = ''; if (!empty($_SERVER['HTTP_CLIENT_IP'])) { $ipaddress = $_SERVER['HTTP_CLIENT_IP']; } elseif (!empty($_SERVER['HTTP_X_FORWARDED_FOR'])) { $ipaddress = $_SERVER['HTTP_X_FORWARDED_FOR']; } else { $ipaddress = $_SERVER['REMOTE_ADDR']; } return $ipaddress; } public function InsertLog ($sql) { $sql->consulta("INSERT INTO tablog (Data, Hora, Acao, Tela, Registro, Usuario, Tipo, Tabela, IdRegistro, Campo, Computador, Grupo) VALUES (NOW(),NOW(),:Acao, :Tela, :Registro, :Usuario, :Tipo, :Tabela, :IdRegistro, :Campo, :Computador, :Grupo)",$this->ArrayLog()); } }