When enabling PHP version 7.2.17 or newer on my site, I get a PHP-related error message on some pages.
Warning: Use of undefined constant comment_notes_before - assumed 'comment_notes_before' (this will throw an Error in a future version of PHP) in /home/(username)/public_html/(domain name)/wp-content/themes/Divi-child/comments.php on line 68
Here is the code on line 68 of the comments.php file:
comment_form( array( 'fields' => $fields, 'label_submit' => esc_attr__( 'Submit', 'Divi' ), 'title_reply' => '<span>' . esc_attr__( 'Leave a comment', 'Divi' ) . '</span>', 'title_reply_to' => esc_attr__( 'Leave a Reply to %s', 'Divi' ), 'class_submit' => 'submit et_pb_button', comment_notes_before
And here is line 69:
=>'<p class="comment-notes">' . __( '' ) . '</p>' ) ); ?>
Any ideas what could be causing this and what adjustments I need to make to the PHP source code?
When enabling PHP version 7.2.17 or newer on my site, I get a PHP-related error message on some pages.
Warning: Use of undefined constant comment_notes_before - assumed 'comment_notes_before' (this will throw an Error in a future version of PHP) in /home/(username)/public_html/(domain name)/wp-content/themes/Divi-child/comments.php on line 68
Here is the code on line 68 of the comments.php file:
comment_form( array( 'fields' => $fields, 'label_submit' => esc_attr__( 'Submit', 'Divi' ), 'title_reply' => '<span>' . esc_attr__( 'Leave a comment', 'Divi' ) . '</span>', 'title_reply_to' => esc_attr__( 'Leave a Reply to %s', 'Divi' ), 'class_submit' => 'submit et_pb_button', comment_notes_before
And here is line 69:
=>'<p class="comment-notes">' . __( '' ) . '</p>' ) ); ?>
Any ideas what could be causing this and what adjustments I need to make to the PHP source code?
Share Improve this question edited May 2, 2019 at 19:37 Mr Ethernet asked May 2, 2019 at 19:08 Mr EthernetMr Ethernet 1035 bronze badges1 Answer
Reset to default 1Please try to change that line to
comment_form( array( 'fields' => $fields, 'label_submit' => esc_attr__( 'Submit', 'Divi' ), 'title_reply' => '<span>' . esc_attr__( 'Leave a comment', 'Divi' ) . '</span>', 'title_reply_to' => esc_attr__( 'Leave a Reply to %s', 'Divi' ), 'class_submit' => 'submit et_pb_button', 'comment_notes_before'
发布者:admin,转转请注明出处:http://www.yc00.com/questions/1745530534a4631673.html
评论列表(0条)