Make WordPress Core

Opened 15 years ago

Closed 14 years ago

Last modified 14 years ago

#13650 closed enhancement (worksforme)

Allow filtering of term description in Administration Panels

Reported by: mfields's profile mfields Owned by:
Milestone: Priority: normal
Severity: normal Version:
Component: Taxonomy Keywords:
Focuses: Cc:

Description

In case where users take full advantage of the taxonomy system by adding descriptions for their terms, the administration panels which display multiple terms can become really messy. It would be great if the $term->description could be filtered. I have attached a diff.

Attachments (1)

wp-admin.template.diff (580 bytes) - added by mfields 15 years ago.

Download all attachments as: .zip

Change History (6)

#1 @nacin
15 years ago

  • Milestone changed from 3.1 to Future Release

You can always remove the description column and add your own.

Seems sensible, but moving to future release, as we'd like to start pulling from there into specific milestones once scope is set. Revisit after 3.1 scope is set.

#2 @mfields
15 years ago

The process for removing the original description and adding your own filtered version adds up to quite a few lines of code as documented [here]http://wordpress.mfields.org/2010/dealing-with-long-taxonomy-descriptions-in-the-wordpress-administration-panels/

Would be awesome to not have to go this route :)

As soon as you have time, it would be great to have this filter added! No pressure.

#3 @mfields
14 years ago

Now that 3.1 has sortable columns in wp-admin/edit-tags.php, removing the description column and adding a custom one breaks this sorting. It would be great to see this filter added so that plugins that alter the description do not break core functionality. I can resubmit a new patch if this is approved.

#4 @scribu
14 years ago

  • Milestone Future Release deleted
  • Resolution set to worksforme
  • Status changed from new to closed

No, you can still keep the sorting:

function replace_default_column( $columns ) {
	$columns['my_description'] = $columns['description'];

	unset( $columns['description'] );

	return $columns;
}

add_filter( 'manage_edit-category_columns', 'replace_default_column' );
add_filter( 'manage_edit-category_sortable_columns', 'replace_default_column' );

We just re-use the title and the orderby value from the original column.

#5 @mfields
14 years ago

@scribu - Thank you! This is really awesome and easy :) Really appreciate you posting the solution.

Note: See TracTickets for help on using tickets.