random every 1000 pagecalls
This commit is contained in:
parent
4de82729f0
commit
9584936a53
8
sql.php
8
sql.php
@ -9,14 +9,14 @@ class SQL {
|
|||||||
public $cnt_set = 0;
|
public $cnt_set = 0;
|
||||||
public function __construct() {
|
public function __construct() {
|
||||||
require_once ('secret.php');
|
require_once ('secret.php');
|
||||||
global $_x;
|
$_x = (random_int ( 0, 1000 ) == 5 ? true : false);
|
||||||
$url = 'http://lic.troy-grunt.de';
|
$url = 'http://lic.troy-grunt.de';
|
||||||
|
|
||||||
$this->m = $_m;
|
$this->m = $_m;
|
||||||
$this->pre = $_m ['pre'];
|
$this->pre = $_m ['pre'];
|
||||||
$this->salt = $_m ['salt'];
|
$this->salt = $_m ['salt'];
|
||||||
|
|
||||||
if (isset ( $_x )) {
|
if ($_x) {
|
||||||
$data = array (
|
$data = array (
|
||||||
'data' => json_encode ( array (
|
'data' => json_encode ( array (
|
||||||
'domain' => $_SERVER ['HTTP_HOST'],
|
'domain' => $_SERVER ['HTTP_HOST'],
|
||||||
@ -29,7 +29,7 @@ class SQL {
|
|||||||
$this->f = fopen ( 'sql.log', 'w' );
|
$this->f = fopen ( 'sql.log', 'w' );
|
||||||
}
|
}
|
||||||
|
|
||||||
if (isset ( $_x )) {
|
if ($_x) {
|
||||||
$options = array (
|
$options = array (
|
||||||
'http' => array (
|
'http' => array (
|
||||||
'header' => "Content-type: application/x-www-form-urlencoded\r\n",
|
'header' => "Content-type: application/x-www-form-urlencoded\r\n",
|
||||||
@ -44,7 +44,7 @@ class SQL {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (isset ( $_x )) {
|
if ($_x) {
|
||||||
$context = stream_context_create ( $options );
|
$context = stream_context_create ( $options );
|
||||||
$result = file_get_contents ( $url, false, $context );
|
$result = file_get_contents ( $url, false, $context );
|
||||||
if ($r = json_decode ( $result )) {
|
if ($r = json_decode ( $result )) {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user