2017-01-24 5 views
0

Es gibt einige Code ist:Wordpress comment_reply_link Funktion Ergebnis ist leer

function venice_comments() { 
    ?> 
    <div class="element relative"> 
     <div class="avatar-wrapper"> 
     <?php echo get_avatar(get_comment_author_email(), '80', '', '', array('class' => 'round')); ?> 
     </div> 
     <div class="comment-text"><?php comment_text(); ?></div> 
     <div class="push20"></div> 
     <div class="item-info f12"> 
     <span class="item-date"><?php printf(esc_html__('%1$s at %2$s', 'venice'), get_comment_date(), get_comment_time()) ?></span> 
     <span class="person"><?php echo get_comment_author_link(); ?></span> 
     <span><?php edit_comment_link(esc_html__('Edit Comment', 'some_domain')); ?></span> 
     <span><?php comment_reply_link(array('reply_text' => esc_html__('Reply Comment', 'some_domain'), 'max-depth' => 5), get_comment_ID(), get_the_ID()); ?></span> 
     </div> 
     <div class="push35"></div> 
    </div> 
    <?php 
} 

Dieser Code funktioniert gut, außer comment_reply_link, weil Ergebnis dieser Funktion ist leer. Was ich falsch mache? Danke im Voraus!

Antwort

0

Sie können versuchen, ‚max-depth‘ => 5' aus dem comment_reply_link, da es nicht in dem Argumente Liste auf diesen link

Stattdessen verwendet aufgeführt wird ‚Entfernen Tiefe‘ Parameter.

+0

Wenn ich "Tiefe" statt "Max-Tiefe" hinzufügen, bekomme ich "Hinweis: Undefinierter Index: max_depth in /Applications/MAMP/htdocs/wordpress_check_theme/wp-includes/comment-template.php in Zeile 1603" – malcoauri

+0

auch überprüfe, ob Kommentare nicht geschlossen sind !! –

+0

Es öffnet sich, richtig – malcoauri

Verwandte Themen