Make WordPress Core

Opened 8 years ago

Closed 6 years ago

#5654 closed enhancement (invalid)

Add echo parameter to wp_get_archives

Reported by: danielsummers Owned by: westi
Milestone: Priority: normal
Severity: minor Version: 2.5
Component: Template Keywords: has-patch needs-testing
Focuses: Cc:


I have modified the wp_get_archives template tag to add the echo parameter, similar to the way wp_get_categories works. This will allow for manipulation of the results. (I made this change to support a tiered archives, with a year at one level and the months below. Allowing me to retrieve the text lets me put the tree together.) Since I had to change it, I thought I would submit it, to see if it would be useful to put it into the core. I've attached a diff - the change was made against the 2.3.2 released version of general-template.php.

Attachments (3)

diff.txt (1.6 KB) - added by danielsummers 8 years ago.
Diff of echo parameter enhancement
5654.diff (3.4 KB) - added by thee17 8 years ago.
Diff based on trac
5654_2point5.diff (2.6 KB) - added by danielsummers 7 years ago.
Updated diff - based on 2.5, removed extra conditionals per ryan's suggestion

Download all attachments as: .zip

Change History (12)

@danielsummers8 years ago

Diff of echo parameter enhancement

@thee178 years ago

Diff based on trac

comment:1 @thee178 years ago

  • Keywords has-patch added

comment:2 @westi8 years ago

  • Owner changed from anonymous to westi
  • Status changed from new to assigned

comment:3 @ryan8 years ago

Lose all of the conditionals and just do one conditional at the end that either echoes or returns $output.

comment:4 @ffemtcj7 years ago

  • Milestone changed from 2.5 to 2.6

@danielsummers7 years ago

Updated diff - based on 2.5, removed extra conditionals per ryan's suggestion

comment:5 @danielsummers7 years ago

Let me know if I should commit it through svn, using my login here, or if putting the diff here is sufficient.

comment:6 @Nazgul7 years ago

Putting the diff here is sufficient.

Only the core devs have commit access to svn. They'll commit it when they look at the patch and deem it good enough.

comment:7 @Denis-de-Bernardy6 years ago

  • Keywords needs-testing added

comment:8 @Denis-de-Bernardy6 years ago

  • Component changed from General to Template

comment:9 @Denis-de-Bernardy6 years ago

  • Milestone 2.9 deleted
  • Resolution set to invalid
  • Status changed from accepted to closed

seems fixed enough

Note: See TracTickets for help on using tickets.