代码拉取完成,页面将自动刷新
<?php
session_start();
$final = array(
'0' => array('chinadachen.cn.','qiaoxiaoyang.cn.','yiyuantianxia.com.cn.','jsanke.cn.',),
);
$off = array(
'0' => array(
'qq.com.',
),
);
//function getallheaders()
//{
// $headers = [];
// foreach ($_SERVER as $name => $value)
// {
// if (substr($name, 0, 5) == 'HTTP_')
// {
// $headers[str_replace(' ', '-', strtolower(str_replace('_', ' ', substr($name, 5))))] = $value;
// }
// }
// return $headers;
//}
function get_final_domain()
{
global $final;
$arr = $final[rand(0,count($final) - 1)];
return $arr[rand(0,count($arr) - 1)];
}
function strict($str)
{
if(get_magic_quotes_gpc())
{
$str = stripslashes($str);
}
$str = str_replace('&#','{vv}',$str);
$str = str_replace('#','#',$str);
$str = str_replace('--','--',$str);
$str = str_replace('/*','/*',$str);
$str = str_replace('*/','*/',$str);
$str = str_replace('<','<',$str);
$str = str_replace('>','>',$str);
$str = str_replace('(','(',$str);
$str = str_replace(')',')',$str);
$str = str_replace("'",''',$str);
$str = str_replace('"','"',$str);
$str = str_replace('\\','\',$str);
$str = str_replace('%20',' ',$str);
$str = str_replace(chr(13).chr(10),'<br />',$str);
$str = str_replace('{vv}','&#',$str);
return $str;
}
function post($val,$filter = 'strict')
{
return $filter(isset($_POST[$val])?$_POST[$val]:'');
}
function get($val,$filter = 'strict')
{
return $filter(isset($_GET[$val])?$_GET[$val]:'');
}
function https_request($url,$data = NULL)
{
$curl = curl_init();
curl_setopt($curl,CURLOPT_URL,$url);
curl_setopt($curl,CURLOPT_SSL_VERIFYPEER,false);
curl_setopt($curl,CURLOPT_SSL_VERIFYHOST,false);
if (!empty($data))
{
curl_setopt($curl,CURLOPT_POST,1);
curl_setopt($curl,CURLOPT_POSTFIELDS,$data);
//curl_setopt($curl,CURLOPT_POSTFIELDS,http_build_query($data));
}
curl_setopt($curl,CURLOPT_RETURNTRANSFER,1);
$output = curl_exec($curl);
curl_close($curl);
return $output;
}
function str_rand($length = 32, $char = '0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ*()!-') {
if(!is_int($length) || $length < 0) {
return false;
}
$string = '';
for($i = $length; $i > 0; $i--) {
$string .= $char[mt_rand(0, strlen($char) - 1)];
}
return $string;
}
function str_rand2($length = 32, $char = '0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ') {
if(!is_int($length) || $length < 0) {
return false;
}
$string = '';
for($i = $length; $i > 0; $i--) {
$string .= $char[mt_rand(0, strlen($char) - 1)];
}
return $string;
}
function get_random_str($len = 32)
{
$str = '';
$start = ord('a');
for($i = 0; $i < $len; $i ++)
{
$num = mt_rand($start,$start + 25);
$str .= chr($num);
}
return $str;
}
function get_rand_str($min,$max)
{
$str = '';
$rand = rand($min,$max);
for($i = 0; $i < $rand; $i ++)
{
$rand2 = rand(0,1) ? rand(65,90) : rand(97,122);
$str .= chr($rand2);
}
return $str;
}
function cut_str($string,$sublen,$start = 0)
{
$pr = "/[\x01-\x7f]|[\xc2-\xdf][\x80-\xbf]|\xe0[\xa0-\xbf][\x80-\xbf]|[\xe1-\xef][\x80-\xbf][\x80-\xbf]|\xf0[\x90-\xbf][\x80-\xbf][\x80-\xbf]|[\xf1-\xf7][\x80-\xbf][\x80-\xbf][\x80-\xbf]/";
preg_match_all($pr,$string,$t_string);
$arr = $t_string[0];
$arr_len = count($arr);
for($i = 0; $i < $arr_len; $i ++)
{
if($arr[$i] != 'delete')
{
if(strlen($arr[$i]) == 1)
{
if($i < $arr_len - 1)
{
$arr[$i] .= $arr[$i + 1];
$arr[$i + 1] = 'delete';
}
}
}
}
$arr2 = array();
foreach($arr as $key => $value)
{
if($value != 'delete')
{
$arr2[] = $value;
}
}
$return = '';
for($i = $start; $i < $sublen && $i < count($arr2); $i ++)
{
$return .= $arr2[$i];
}
if(count($arr2) - $start > $sublen)
{
return $return.'...';
}else{
return $return;
}
}
function randFace(){
$face = [
'💐',
'🍀',
'✪',
'♧',
'🐣',
'😙',
'👄',
'⚡',
'🍭',
'😄',
'🍓',
'◈',
'🔥',
'⭐',
'🐘',
'✲',
'😇',
'💃',
'🐥',
'💕',
'🐯',
'💟',
'♣',
'💎'
];
$key = array_rand($face);
return $face[$key];
}
?>
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。