Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/php/296.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Php 正在停止加载css文件_Php_Wordpress - Fatal编程技术网

Php 正在停止加载css文件

Php 正在停止加载css文件,php,wordpress,Php,Wordpress,如何阻止quick-style.css在此网站deeswholefoods.com上加载?这会减慢整个站点的速度 <link rel="stylesheet" id="quick-style-css" href="http://deeswholefoods.com/wp-content/themes/organic-life/quick-style.php?ver=4.3.1" type="text/css" media="all"> 你知道我还能尝试什么吗?你的快速样式css函数

如何阻止quick-style.css在此网站deeswholefoods.com上加载?这会减慢整个站点的速度

<link rel="stylesheet" id="quick-style-css" href="http://deeswholefoods.com/wp-content/themes/organic-life/quick-style.php?ver=4.3.1" type="text/css" media="all">
你知道我还能尝试什么吗?

你的快速样式css函数名不匹配。您钩住了dequeue\u quick-style-css,然后将函数命名为dequeue\u my\u css。应该这样匹配:

function dequeue_quick-style-css() {
  wp_dequeue_style('quick-style-css');
  wp_deregister_style('quick-style-css');
}
add_action('wp_enqueue_scripts','dequeue_quick-style-css');

使用此功能时:wp_enqueue_样式

Wp add-样式表id末尾的css

也许试着这样做:

 function custom_styles() {
   // remove "-css" at the end of the stylesheet
    wp_deregister_style( 'quick-style' );
    wp_register_style( 'quick-style', '', false, false );
}
add_action( 'wp_enqueue_scripts', 'custom_styles' );

您是否尝试编辑主题的header.php?wp content/themes/organic life/header.php感谢你指出这一点,我错过了。不幸的是,它没有解决这个问题。
 function custom_styles() {
   // remove "-css" at the end of the stylesheet
    wp_deregister_style( 'quick-style' );
    wp_register_style( 'quick-style', '', false, false );
}
add_action( 'wp_enqueue_scripts', 'custom_styles' );