-1
我使用此代碼中的所有頁面禁用auto paragraph
和br
:條件語句中的functions.php不工作
remove_filter('the_content', 'wpautop');
remove_filter('the_excerpt', 'wpautop');
後來我決定,我想汽車<p>
和<br />
行爲是那樣的,在taxonomy => blog-cat
,所以我來了與此代碼:
function remove_auto(){
if(!is_tax('blog-cat')){
remove_filter('the_content', 'wpautop');
remove_filter('the_excerpt', 'wpautop');
}
}
add_action('wp_head','remove_auto',0);
但不幸的是,它不工作。
有沒有人有想法?
您需要提供更多信息。 – EternalHour 2014-11-03 03:50:49
這對於......有什麼作用? – Ohgodwhy 2014-11-03 04:05:34