Make WordPress Core

Opened 8 years ago

Closed 4 years ago

#35910 closed enhancement (fixed)

Allow wp_credits() to accept custom wordpress versions and locals

Reported by: ramiy's profile ramiy Owned by: sergeybiryukov's profile SergeyBiryukov
Milestone: 5.6 Priority: normal
Severity: normal Version:
Component: Administration Keywords: has-patch
Focuses: administration Cc:


Introduced in wordpress 3.2, wp_credits() retrieve the contributor credits from This function doesn't accept any parameter, it retrieves data only for the current wordpress version and local.

As a plugin developer, if I want to get wordpress credits information for older versions or different locals, I can't do that using wp_credits().

But It can be easily fixed. The function just need to accept the version and the local as parameters. For backwards compatibility, if the parameters are empty, we will use the current version and local.

See the attached patch.

Attachments (1)

35910.patch (1.4 KB) - added by ramiy 8 years ago.

Download all attachments as: .zip

Change History (6)

8 years ago

#2 @Presskopp
8 years ago

  • Keywords has-patch added

#3 @ramiy
4 years ago

This is a minor update. Instead of using hardcoded $wp_version and get_locale() inside a function. The function can accept the version and the local as parameters. If no parameters set, the function defaults to $wp_version and get_locale().

#4 @SergeyBiryukov
4 years ago

  • Milestone set to 5.6

#5 @SergeyBiryukov
4 years ago

  • Owner set to SergeyBiryukov
  • Resolution set to fixed
  • Status changed from new to closed

In 48715:

Administration: Allow wp_credits() to accept $version and $locale parameters.

This can be helpful for plugin developers to get credits information for older versions or different locales.

Props ramiy.
Fixes #35910.

Note: See TracTickets for help on using tickets.