0

I've been adding some data to the columns of two taxonomies in a theme I'm working on. I've hit something that's got me confused though.
I'm using this hook manage_{$taxonomy}_custom_column but the Adam Brown page on the hook says it's no longer in use. When using the hook I get no errors, so can this be true? I can't seem to find a replacement either. How can I tell if my hook, or any other hook, is deprecated?

1

manage_{$taxonomy}_custom_column is a dynamic hook, so until you are using a proper value for $taxonomy like post_tag, it would work perfectly.

Adam Brown page tells it as deprecated because it looks for exact match, while there is a change in the files so the current hook being used are manage_{$this->screen->taxonomy}_custom_column or manage_{$screen->taxonomy}_custom_column which accepts the same value whether it is post_tag or something else, and that's the reason you don't get error or warning.

  • I did think that the $this->screen->taxonomy property would be giving the same value as just passing $taxonomy. So, in a nut shell, everything is fine with this : ) Thanks for taking a look into this for me. – Dan Jan 6 '14 at 6:52
  • Cheers Dan...!! – Kumar Jan 6 '14 at 7:05

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.