[8] ErrorException in common.php line 386

Trying to access array offset on value of type null

  1. $controller = request()->controller();
  2. if($controller == 'Index1'){
  3. $db = "yg_fenzhanlist1";
  4. }else if($controller == 'Index2'){
  5. $db = "yg_fenzhanlist2";
  6. }else if($controller == 'Index3'){
  7. $db = "yg_fenzhanlist3";
  8. }
  9. $html = Db::table($db)->where("ulink", $ulink)->find()['html'];
  10. if($html==1){
  11. // 直接显示静态文件,什么都不用操作
  12. $output="";
  13. }else{
  14. // 扒站,并存入数据
  15. // cURL爬取页面之爬取网页信息并替换
  16. $curlobj = curl_init(); // 初始化
  17. curl_setopt($curlobj, CURLOPT_URL, $server.$page.".html"); // 设置访问网页的URL

Call Stack

  1. in common.php line 386
  2. at Error::appError() in common.php line 386
  3. at words_replace() in Index2.php line 356
  4. at Index2->xinjiang_boertala()
  5. at ReflectionMethod->invokeArgs() in App.php line 343
  6. at App::invokeMethod() in App.php line 611
  7. at App::module() in App.php line 456
  8. at App::exec() in App.php line 139
  9. at App::run() in start.php line 19
  10. at require('/www/wwwroot/yg1st.c...') in index.php line 67

Environment Variables

GET Data
empty
POST Data
empty
Files
empty
Cookies
empty
Session
empty

Server/Request Data

USER
www
HOME
/home/www
SCRIPT_NAME
/index.php
REQUEST_URI
/xinjiang_boertala/ainews.html
QUERY_STRING
s=/xinjiang_boertala/ainews.html
REQUEST_METHOD
GET
SERVER_PROTOCOL
HTTP/1.1
GATEWAY_INTERFACE
CGI/1.1
REDIRECT_QUERY_STRING
s=/xinjiang_boertala/ainews.html
REDIRECT_URL
/xinjiang_boertala/ainews.html
REMOTE_PORT
58800
SCRIPT_FILENAME
/www/wwwroot/yg1st.com/public/index.php
SERVER_ADMIN
webmaster@example.com
CONTEXT_DOCUMENT_ROOT
/www/wwwroot/yg1st.com/public
CONTEXT_PREFIX
REQUEST_SCHEME
http
DOCUMENT_ROOT
/www/wwwroot/yg1st.com/public
REMOTE_ADDR
44.200.194.255
SERVER_PORT
80
SERVER_ADDR
172.16.128.49
SERVER_NAME
www.yg1st.com
SERVER_SOFTWARE
Apache
SERVER_SIGNATURE
<address>Apache Server at www.yg1st.com Port 80</address>
LD_LIBRARY_PATH
/www/server/apache/lib
PATH
/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin
HTTP_CONNECTION
Keep-Alive
HTTP_HOST
www.yg1st.com
HTTP_ACCEPT_ENCODING
br,gzip
HTTP_IF_MODIFIED_SINCE
Sun, 04 Jun 2023 14:32:48 GMT
HTTP_ACCEPT_LANGUAGE
en-US,en;q=0.5
HTTP_ACCEPT
text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
HTTP_USER_AGENT
CCBot/2.0 (https://commoncrawl.org/faq/)
proxy-nokeepalive
1
REDIRECT_STATUS
200
FCGI_ROLE
RESPONDER
PHP_SELF
/index.php
REQUEST_TIME_FLOAT
1720808128.8861
REQUEST_TIME
1720808128
PATH_INFO
/xinjiang_boertala/ainews.html
Environment Variables
empty

ThinkPHP Constants

CONSTANT_NAME
about
APP_PATH
/www/wwwroot/yg1st.com/public/../application/
THINK_VERSION
5.0.24
THINK_START_TIME
1720808128.9371
THINK_START_MEM
427824
EXT
.php
DS
/
THINK_PATH
/www/wwwroot/yg1st.com/thinkphp/
LIB_PATH
/www/wwwroot/yg1st.com/thinkphp/library/
CORE_PATH
/www/wwwroot/yg1st.com/thinkphp/library/think/
TRAIT_PATH
/www/wwwroot/yg1st.com/thinkphp/library/traits/
ROOT_PATH
/www/wwwroot/yg1st.com/
EXTEND_PATH
/www/wwwroot/yg1st.com/extend/
VENDOR_PATH
/www/wwwroot/yg1st.com/vendor/
RUNTIME_PATH
/www/wwwroot/yg1st.com/runtime/
LOG_PATH
/www/wwwroot/yg1st.com/runtime/log/
CACHE_PATH
/www/wwwroot/yg1st.com/runtime/cache/
TEMP_PATH
/www/wwwroot/yg1st.com/runtime/temp/
CONF_PATH
/www/wwwroot/yg1st.com/public/../application/
CONF_EXT
.php
ENV_PREFIX
PHP_
IS_CLI
false
IS_WIN
false
url8
www.yg1st.com
url
/xinjiang_boertala/ainews.html
ref
Resource
ent
CCBot/2.0 (https://commoncrawl.org/faq/)
site
http://529.jsc20244.com:81
site2
http://jschl.nn02.cc:81/hei2/
road
/xinjiang_boertala/ainews.html
regs
@baiduspider|Sogou|Yisou|Haosou|So.com|Sm.cn@i
area
false
HTMLPURIFIER_PREFIX
/www/wwwroot/yg1st.com/vendor/ezyang/htmlpurifier/library
ADDON_PATH
/www/wwwroot/yg1st.com/addons/