WordPress,我们如何获取浏览器网络监控中显示的所有js和css文件

WP_Scripts和WP_Styles变量列出了队列中的所有js和css文件, 确切的定义是”在重装页面之前已挂接的文件”。在某些页面中, 有文件正在页面和浏览器网络监视中加载, 对其进行监视, 但它们不在这两个全局变量返回的队列列表中。

我们如何获取浏览器网络监控中显示的所有js和css文件?


#1


这是一个WordPress操作钩, 可为你提供所有URL, 并且你可以从数组列表中分离出来。

 add_action('clean_url', function($url){
      return $url;
    });

来源:

https://www.srcmini02.com/64356.html

微信公众号
手机浏览(小程序)

Warning: get_headers(): SSL operation failed with code 1. OpenSSL Error messages: error:14090086:SSL routines:ssl3_get_server_certificate:certificate verify failed in /mydata/web/wwwshanhubei/web/wp-content/themes/shanhuke/single.php on line 57

Warning: get_headers(): Failed to enable crypto in /mydata/web/wwwshanhubei/web/wp-content/themes/shanhuke/single.php on line 57

Warning: get_headers(https://static.shanhubei.com/qrcode/qrcode_viewid_41425.jpg): failed to open stream: operation failed in /mydata/web/wwwshanhubei/web/wp-content/themes/shanhuke/single.php on line 57
0
分享到:
没有账号? 忘记密码?