We can use comment_form
function’s submit_button
parameter to change submit button HTML.
Default HTML for submit_button
is
<input name="%1$s" type="submit" id="%2$s" class="%3$s" value="%4$s" />
You can change your code like this.
$comments_args = array(
....
'submit_button' => '<div class="form-group">
<input name="%1$s" type="submit" id="%2$s" class="%3$s" value="%4$s" />
</div>'
....
);
Update:
Regarding %1$s
, %2$s
and so on..
If you take a look at comment_form() source, you can see that submit_button
is going through sprintf like this.
$submit_button = sprintf(
$args['submit_button'],
esc_attr( $args['name_submit'] ),
esc_attr( $args['id_submit'] ),
esc_attr( $args['class_submit'] ),
esc_attr( $args['label_submit'] )
);
Related Posts:
- customize comment form
- comment_post action hook running on page load instead of after a comment is posted
- How to make comments private for commentor and post author
- Name of comment field differs on different sites
- How can I embed comments plugin to my own website?
- Custom comment field not showing when logged-in
- How to display replies to his comments in user profile of current user
- reply comment below the comment box without reload page
- How to call out the date of user’s first comment?
- How to pass settings to comment_form() if theme only uses comments_template()?
- How to add a class to comment submit button?
- reply to comment excerpt instead of author in comment title
- Display Comment Form on dedicated Page for each post
- Commentform – Hightlight invalid fields instead of prompting towards error page
- How to add a class to the comment submit button?
- Comment Walker vs. Comment Callback
- comments reply script not working
- How to display comment form error messages in the same page
- How do I set up real anonymous posting in bbpress forums? [closed]
- Showing comments only to same custom user role
- Why does comment_reply_link launch the reply form at the wrong spot on the comment section?
- How to allow the reply link to remain on the comment form after I have reached my 10 nested comment limit?
- Deep customization of the comment form?
- How to hide “Trackback” on paginated comments
- Why are default comments deprecated?
- Comments Reply Form
- Does WordPress Allow Blank/Empty Comment Submissions In WordPress?
- Comment form not showing up without comments
- How can comments be submitted when I don’t have a comment box on a page?
- how to have 2 comments_template() in one post
- Making a Comment on a page without being on that page?
- How can I show comments in random order?
- adding a text message beside the comment submit button
- How to save new comment as custom comment type?
- WP comments form (custom) is displaying an extra comment field
- How to modify comments form using comment_form()?
- How to add consent checkbox in comment section
- Publish a message on facebook after having posted a comment
- Edit Comment_Field while using T5 Comment Textarea On Top-Plugin
- How to add a title field in comments?
- Share comment to twitter after publishing [closed]
- How to add attributes to the comment form tag?
- The comment login form is visible to me but not to the user
- How to call my custom WordPress Comment form without getting the comments?
- How can I test why the comment hook is not working?
- How can I convert anonymous commenters into registered users?
- using comments_template() in custom single-portfolio.php
- how to properly use comments-template.php
- customizing TwentyEleven comments template
- blank page after submitting a comment
- Notification if Comment Author Field is left empty. E.g. change input border colour
- Modify WordPress Comment From For AMP Html
- Check if comment was successfully submited
- Ajax submit comments
- Enable nested comments in Theme
- Display avatar with comment form?
- How to display comment meta under each comment content
- comment_notes_before not working
- How to create post comment from different domain
- Get comment id of the individual comments in comment list when modifying comment posted using comment text filter
- Custom comment link
- Comments on future posts
- get_comment_meta not behaving as expected
- unsetting required fields in the comment reply form
- Returning error upon comment being flagged as spam
- Clicking Comment “Reply” Button only replies to first comment
- Changing the Comment Fields using Filter (without success)
- Cannot Remove Title Reply from Custom Comment Template for Signup Page
- How do I make the comment disappear after deleting from the database?
- comment just attachment .. reply just text … can I do that?
- Custom sort comments with select form
- Edit Comments Fields
- Same comment section on every page
- Update post “A” on comment submition on post “B”
- Upload avatar for post comment
- How to show a list of comments on home page from all posts?
- Force to show all fields in comment forms to the logged-in users
- How to make comment reply available only for login members of a certain user roles only?
- Removing(replacing) avtar in comments.php with some other HTML arrangements
- edit comments in front end
- How to replace anonymous comment form with a registration form on wordpress?
- How Can I display the Current Logged-In User’s Comment at the Top of the Comments Section in WordPress?
- Comments page id wp_list_comments
- Redirect first time comments
- Increase Comment Author Gravatar Size On WordPress Default Comment Function
- Adding restrictions to open comments
- wp-editor-area textarea disapear on cancel-comment-reply-link click
- How to maintain changes to comment-template.php
- Comment form – different title if no comment yet
- WordPress Comments jQuery Doesn’t submit
- Insert comment and still use moderation
- Auto approve all comments (editor)
- add field comment [duplicate]
- How do I convert users who put an email and username for a comment into registered users? [duplicate]
- Merge comments from Facebook with WP comments [closed]
- Why default comment fields don’t show up?
- How to enable truly anonymous posting in bbPress forums? [closed]
- Replace Entire Comment Box with Text
- How to hide and disable URL and email fields from comments?
- The last comments of a post for the author of that post