作者 lyh

gx查询排除独立白帽系统

@@ -396,8 +396,7 @@ class KeywordLogic extends BaseLogic @@ -396,8 +396,7 @@ class KeywordLogic extends BaseLogic
396 preg_match_all('/\{[^{}]*\}/', $text, $matches); 396 preg_match_all('/\{[^{}]*\}/', $text, $matches);
397 $data = []; 397 $data = [];
398 $twoMonthsAgo = strtotime('-2 months'); 398 $twoMonthsAgo = strtotime('-2 months');
399 - $randomTimestamp = rand($twoMonthsAgo, time());  
400 - $randomDateTime = date('Y-m-d H:i:s', $randomTimestamp); 399 +
401 if (!empty($text)) { 400 if (!empty($text)) {
402 foreach ($matches[0] as $item) { 401 foreach ($matches[0] as $item) {
403 $item = str_replace("'", '"', $item); 402 $item = str_replace("'", '"', $item);
@@ -406,6 +405,8 @@ class KeywordLogic extends BaseLogic @@ -406,6 +405,8 @@ class KeywordLogic extends BaseLogic
406 if (!isset($item['name']) || !isset($item['comment'])) { 405 if (!isset($item['name']) || !isset($item['comment'])) {
407 continue; 406 continue;
408 } 407 }
  408 + $randomTimestamp = rand($twoMonthsAgo, time());
  409 + $randomDateTime = date('Y-m-d H:i:s', $randomTimestamp);
409 $data[] = [ 410 $data[] = [
410 'nickname' => $item['name'], 411 'nickname' => $item['name'],
411 'text' => $item['comment'], 412 'text' => $item['comment'],