コメントのメールアドレスが管理画面上で表示されない
-
コメントのメールアドレス情報が管理画面上で表示されません。
どこに原因があるかご教授いただけますでしょうか?コメントの入力欄としては、メールアドレスは設けておきサイト上では非表示としたいです。
ただし、管理画面上ではメールアドレス情報を確認できるようにしたいです。現在、comments.phpは以下のソースとなっています。
<div id="comments"> <?php if ( post_password_required() ) : ?> <?php // No Passwords comment ?> </div><!-- #comments --> <?php /* Stop the rest of comments.php from being processed, * but don't kill the script entirely -- we still have * to fully load the template. */ return; endif; ?> <?php // You can start editing here -- including this comment! ?> <?php if ( have_comments() ) : ?> <h3 id="comments-title">コメント</h3> <?php if ( get_comment_pages_count() > 1 && get_option( 'page_comments' ) ) : // Are there comments to navigate through? ?> <div class="navigation"> <div class="nav-previous"><?php previous_comments_link('<span class="meta-nav">←</span> 古いコメント'); ?></div> <div class="nav-next"><?php next_comments_link('新しいコメント <span class="meta-nav">→</span>'); ?></div> </div> <!-- .navigation --> <br /> <?php endif; // check for comment navigation ?> <ol class="commentlist"> <?php wp_list_comments( array( 'callback' => 'biz_vektor_comment' ) ); ?> </ol> <?php if ( get_comment_pages_count() > 1 && get_option( 'page_comments' ) ) : // Are there comments to navigate through? ?> <div class="navigation"> <div class="nav-previous"><?php previous_comments_link('<span class="meta-nav">←</span> 古いコメント'); ?></div> <div class="nav-next"><?php next_comments_link('新しいコメント <span class="meta-nav">→</span>'); ?></div> </div><!-- .navigation --> <?php endif; // check for comment navigation ?> <?php else : if ( ! comments_open() ) :?> <?php // Comment don't open ?> <?php endif; ?> <?php endif; // end have_comments() ?> <?php $defaults = array( 'comment_notes_before' => '',/* ここで「メールアドレスが公開されることはありません」を削除 */ 'fields' => array( 'author' => '<p class="comment-form-author">' . '<label for="author">お名前(ニックネーム可)</label> ' . ( $req ? '<span class="required">*</span>' : '' ) . '<input id="author" name="author" type="text" value="' . esc_attr( $commenter['comment_author'] ) . '" size="30"' . $aria_req . ' /></p>',/* ここは投稿者名のフォーム */ 'email' => '<p class="comment-form-email"><label for="email">メールアドレス(サイト上に公開はされません)</label> ' . ( $req ? '<span class="required">*</span>' : '' ) . '<input id="email" name="email" type="text" value="' . esc_attr( $commenter['comment_author_email'] ) . '" size="30"' . $aria_req . ' /></p>',/* ここはメールアドレスのフォーム。文言を変えてます。 */ 'url' => '',)/* ここはURLのフォーム。削除している。 */ ); ?> <?php comment_form( $defaults ); ?> </div><!-- #comments -->元々、メールアドレスはコメント入力画面で非表示設定としており、「style.css」ファイルで以下の設定をしておりました。
.comment-notes,.comment-form-email{display:none;}ただ、再度、メールアドレスを入力可能項目としたいため、上記のコードを削除しましたが
サイト上ではコメント入力画面でメールアドレス欄が復活しましたが、管理画面では表示されません。他に問題が有るかもしれませんが、どこが原因かわかりません。
ご教授お願いいたします。よろしくお願いいたします。
3件の返信を表示中 - 1 - 3件目 (全3件中)
3件の返信を表示中 - 1 - 3件目 (全3件中)
トピック「コメントのメールアドレスが管理画面上で表示されない」には新たに返信することはできません。