Add “tabindex” to checkbox field?

[ad_1]

Nevermind, I managed to solve the issue.

I turned off “Enable default checkbox” and recreated it in “comment_form_default_fields” filter.

In case anyone else is looking for this solution, this is what I’ve done :

function my_comment_form_fields($args) {
$args['comments_notify'] = '<div class="comment-form-subscriptions">
	<input type="checkbox" name="subscribe-reloaded" id="subscribe-reloaded" tabindex="5" value="replies">
	<label for="subscribe-reloaded">Notify me of replies to my comment via e-mail.</label>
	</div>';
return $args;
}
add_filter('comment_form_default_fields', 'my_comment_form_fields');

 

This site will teach you how to build a WordPress website for beginners. We will cover everything from installing WordPress to adding pages, posts, and images to your site. You will learn how to customize your site with themes and plugins, as well as how to market your site online.

Buy WordPress Transfer