WordPress.org

Make WordPress Core

Changeset 3751


Ignore:
Timestamp:
04/25/2006 08:46:19 AM (15 years ago)
Author:
ryan
Message:

Div balance across more. Props skeltoac. fixes #2348

Location:
trunk/wp-includes
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/functions-formatting.php

    r3717 r3751  
    405405             1.0  First Version
    406406*/
    407 function balanceTags($text, $is_comment = 0) {
    408 
    409     if ( get_option('use_balanceTags') == 0)
     407function balanceTags($text, $is_comment = 0, $force = false) {
     408
     409    if ( !$force && get_option('use_balanceTags') == 0 )
    410410        return $text;
    411411
  • trunk/wp-includes/template-functions-post.php

    r3750 r3751  
    8484    $content = $pages[$page-1];
    8585    $content = explode('<!--more-->', $content, 2);
    86     if ( (preg_match('/<!--noteaser-->/', $post->post_content) && ((!$multipage) || ($page==1))) )
     86    if ( (false !== strpos($post->post_content, '<!--noteaser-->') && ((!$multipage) || ($page==1))) )
    8787        $stripteaser = 1;
    8888    $teaser = $content[0];
     
    9494            $output .= '<a id="more-'.$id.'"></a>'.$content[1];
    9595        else
    96             $output .= ' <a href="'. get_permalink() . "#more-$id\">$more_link_text</a>";
     96            $output = balanceTags($output . ' <a href="'. get_permalink() . "#more-$id\">$more_link_text</a>");
    9797    }
    9898    if ( $preview ) // preview fix for javascript bug with foreign languages
Note: See TracChangeset for help on using the changeset viewer.