mirror of
https://github.com/WordPress/WordPress.git
synced 2025-02-21 15:01:32 +01:00
Revert [14268] - It is much better to use JavaScript for this kind of enhancement. Output buffering is too fragile. See #12564.
git-svn-id: http://svn.automattic.com/wordpress/trunk@14274 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
10a2e47890
commit
90873d5063
@ -1515,11 +1515,10 @@ function comment_form( $args = array(), $post_id = null ) {
|
||||
'title_reply_to' => __( 'Leave a Reply to %s' ),
|
||||
'cancel_reply_link' => __( 'Cancel reply' ),
|
||||
'label_submit' => __( 'Post Comment' ),
|
||||
'echo' => true,
|
||||
);
|
||||
|
||||
$args = wp_parse_args( $args, apply_filters( 'comment_form_defaults', $defaults ) );
|
||||
ob_start();
|
||||
|
||||
?>
|
||||
<?php if ( comments_open() ) : ?>
|
||||
<?php do_action( 'comment_form_before' ); ?>
|
||||
@ -1557,12 +1556,8 @@ function comment_form( $args = array(), $post_id = null ) {
|
||||
<?php do_action( 'comment_form_after' ); ?>
|
||||
<?php else : ?>
|
||||
<?php do_action( 'comment_form_comments_closed' ); ?>
|
||||
<?php endif;
|
||||
$form = apply_filters( 'comment_form_output', ob_get_clean(), $args );
|
||||
if ( $args['echo'] )
|
||||
echo $form;
|
||||
else
|
||||
return $form;
|
||||
<?php endif; ?>
|
||||
<?php
|
||||
}
|
||||
|
||||
?>
|
||||
|
Loading…
Reference in New Issue
Block a user