The theme_submit() function in form.inc doesn't seem to be used anymore. The submit button uses theme_button() through #theme_wrappers. So I guess at one point that function became unnecessary but wasn't deleted. Even if something would want to use it by calling theme('submit') it wouldn't work because it isn't initialized by system_theme().

CommentFileSizeAuthor
#1 remove-theme-submit.patch667 bytesjax

Comments

jax’s picture

Status: Active » Needs review
StatusFileSize
new667 bytes

So, IMO, it can be removed. But the risk of breaking something somewhere might not be worth the couple of removed lines.

Chris Gillis’s picture

Version: 7.9 » 7.x-dev
Issue summary: View changes
Status: Needs review » Needs work

I can confirm that this issue is still extant. My suggestion is simply to add a note to the docblock comment specifying that this is deprecated, and theme_button should be used instead. Deleting it is not recommended because sites may be initialising it themselves, but relying on core's definition.

Status: Needs work » Closed (outdated)

Automatically closed because Drupal 7 security and bugfix support has ended as of 5 January 2025. If the issue verifiably applies to later versions, please reopen with details and update the version.