• a bug has crept in somewhere between 7.7 and 8.8 which stops the player appearing if you set “before <!–more–> tag” to NO.

    podpress_class.php — search for “if(!$hasLocationDefined)” and look at the logic on the next line

    in 7.7 (line 589)

    if($this->settings['contentBeforeMore'] == 'no') {
    	return $content;
    }

    in 8.8 (line 663)

    if($this->settings['contentBeforeMore'] == 'no' && strstr($content, '#more')) {
    	return $content;
    }

    i edited back to the 7.7 version and it seems to work as desired. this makes sense as the 8.8 version just returns if you set NO regardless. whereas 7.7 if you set NO and there IS a more tag in your post.

    (I’m posting here rather than the podpress forum cos i’m reg’d here!)

Viewing 3 replies - 1 through 3 (of 3 total)
  • The code listed above was already in my version of podpress_class.php and the player does not show up at all when I set the ‘Before <!- More -> tag’ to ‘No’. I don’t want the podpress stuff to show up in the excerpt only on the post page. Maybe I am doing something wrong.

    After taking a look at the code, I made some changes that seem to work.

    podpress_class.php line 623 below GLOBAL $post I changed:

    unset($this->tempContentAddedTo[$post->ID]);
    $content = $this->insert_content($content);
    unset($this->tempContentAddedTo[$post->ID]);
    return $content;

    To this:

    if($this->settings['contentBeforeMore'] == 'yes') {
       unset($this->tempContentAddedTo[$post->ID]);
       $content = $this->insert_content($content);
       unset($this->tempContentAddedTo[$post->ID]);
    }
    return $content;

    Then I commented out lines 665 – 667:

    /*if($this->settings['contentBeforeMore'] == 'no') {
        return $content;
    }*/

    Hope this helps, maybe someone else could take a look at it and make sure that it is not going to break something else.

    Thanks, slicksno. Your fix worked for me. Doesn’t seem to cause problems anywhere else.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘before more tag bug FIXED in podpress’ is closed to new replies.