Make WordPress Core

Opened 11 years ago

Closed 11 years ago

#24626 closed enhancement (duplicate)

Add a class to comment_form's <form> output

Reported by: chrisvanpatten's profile chrisvanpatten Owned by:
Milestone: Priority: normal
Severity: minor Version: 3.5
Component: Comments Keywords: has-patch
Focuses: Cc:

Description

It's a tad frustrating that you can't add a class to the <form> tag that's generated in the comment_form function. I know you can wrap the function in a <div> but it is gratuitous markup. Bootstrap (and I'm sure other frameworks) suggest adding classes to <form> elements too, and while they probably work by wrapping with a <div> as well, it is frustrating you can't follow their recommendations exactly.

There have been a number of tickets about the ability to add classes to the comment form's submit button—#20446, #15015, et al.—but none (that I can find) focusing on the ability to add custom classes to the <form> tag itself.

Thanks!

Attachments (1)

24626.diff (1.8 KB) - added by chrisvanpatten 11 years ago.

Download all attachments as: .zip

Change History (3)

#1 @chrisvanpatten
11 years ago

  • Keywords has-patch added

This is my first patch, so I hope I did it right!

#2 @SergeyBiryukov
11 years ago

  • Milestone Awaiting Review deleted
  • Resolution set to duplicate
  • Status changed from new to closed
  • Version changed from trunk to 3.5

Duplicate of #23851.

Note: See TracTickets for help on using tickets.