• I’m a new admin on an oddly designed custom WP site, walkleys.com — I don’t know what the theme is or where it came from.

    The post editor is missing an excerpt field. (It’s not in the top-right custom options, either.)

    I checked my functions.php and it does refer to an excerpt.

    Where an excerpt would ordinarily appear, the site is pulling the first few lines of raw HTML instead (with the tags included, not stripped).

    Others who had this problem found a naughty plugin called Advanced Custom Fields that had broken the excerpt. My site doesn’t have that one but it does have another called Custom Post Suite that is described as a lightweight version of ACS, so I wonder if that is the issue. Unfortunately I cannot deactivate it because it is (oddly) being used to form the basic architecture of the content. There are a bunch of other plugins, some of which I’ve disabled and others I’m afraid to. I’d appreciate any insights into what I could do to identify the problem.

    Here’s the only part of my functions.php that refers to excerpts. Not sure what other theme files I should be looking at.

    function get_excerpt($post, $length){
    
    	if(has_excerpt($post)){
    		$excerpt = $post->post_excerpt;
    	}else{
    		$excerpt = $post->post_content;
    	}
    
    	$excerpt = strip_tags($excerpt);
    
    	if(strlen($excerpt) > $length){
    		$excerpt = mb_substr($excerpt, 0, $length, 'UTF8').' ...';
    	}
    
    	return $excerpt;
    }
  • The topic ‘Excerpt field is missing from post editor’ is closed to new replies.