I'd like to remove auto formatting 'wpautop' from specific pages. Here is what I've got, but it doesn't appear to work:
if ( is_page ( 'services' ) ) {
remove_filter( 'the_content', 'wpautop' );
remove_filter( 'the_excerpt', 'wpautop' );
};
I am quite new to php, I have done some research to see how to write this statement, but I have had trouble finding an example that addresses my need. What would be the correct way to write this conditional statement?