//输出替换
'tpl_replace_string' => [
'__STATIC__'=>$_SERVER['REQUEST_SCHEME'] .'://' . $_SERVER['HTTP_HOST'] . str_replace('/index.php' ,'' ,$_SERVER['SCRIPT_NAME']) . '/static',
'__IMG__'=>$_SERVER['REQUEST_SCHEME'] .'://' . $_SERVER['HTTP_HOST'] . str_replace('/index.php' ,'' ,$_SERVER['SCRIPT_NAME']) . '/uploads',
],
我解决了
It is recommended that you use the relative path of the entry file to introduce the static file. I think the first one is no problem. You can print it on the page _STATIC_ and take a look.
//输出替换
'tpl_replace_string' => [
'__STATIC__'=>$_SERVER['REQUEST_SCHEME'] .'://' . $_SERVER['HTTP_HOST'] . str_replace('/index.php' ,'' ,$_SERVER['SCRIPT_NAME']) . '/static',
'__IMG__'=>$_SERVER['REQUEST_SCHEME'] .'://' . $_SERVER['HTTP_HOST'] . str_replace('/index.php' ,'' ,$_SERVER['SCRIPT_NAME']) . '/uploads',
],
我解决了
It is recommended that you use the relative path of the entry file to introduce the static file. I think the first one is no problem. You can print it on the page _STATIC_ and take a look.