XPressME Integration Kit

Trac


Ignore:
Timestamp:
Aug 11, 2009, 4:31:35 PM (15 years ago)
Author:
toemon
Message:

WP2.1.3MEへの対応 fixed #199
但しWP2.1.3ME自体のバグ(MySQL4.1以上でEUC-JPを使用したときの文字化け)があるので注意

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/xpressme_integration_kit/wp-content/themes/xpress_default/blocks/recent_comments_block_theme.php

    r269 r360  
    4646                $comment_sql  = "SELECT comment_ID,comment_post_ID,comment_author,comment_author_email,comment_author_url,comment_content, comment_type,UNIX_TIMESTAMP(comment_date) as comment_unix_time "; 
    4747                $comment_sql .= "FROM $wpdb->comments LEFT JOIN $wpdb->posts ON  $wpdb->posts.ID = $wpdb->comments.comment_post_ID "; 
    48                 if (xpress_is_wp20()){ 
     48                if (xpress_is_wp_version('<','2.1')){ 
    4949                        $comment_sql .= "WHERE comment_approved = '1' AND post_status = 'publish' $type_select "; 
    5050                } else { 
     
    6060                                $comment_content = $comment->comment_content; 
    6161                                $comment_excerpt = ($disp_length>0 ? xpress_substr($comment_content, 0, $disp_length): $comment->comment_content); 
    62                                 if (xpress_is_wp20()){ 
    63                                         $comment_link = get_permalink($comment->comment_post_ID) . '#comment-' . $comment->comment_ID ; 
    64                                 } else { 
    65                                         $comment_link = get_comment_link($comment->comment_ID); 
    66                                 } 
     62                                $comment_link = get_comment_link($comment->comment_ID); 
    6763                                $comment_title = $comment_excerpt; 
    6864                                $comment_title_link = "<a href='$comment_link' rel='external nofollow' class='url'>$comment_title</a>"; 
Note: See TracChangeset for help on using the changeset viewer.