Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

I have a custom bit of code that I need to place on the category edit screen but not on the manage categories screen.

Prior to WordPress 3.5, I was able to set a global $action variable to check for action="edit" and place my code.

The same action variable returns empty in 3.5

share|improve this question
    
Don't set global variables. WordPress has hundreds, and you'll likely clash with them. Probably a $actionvariable was made global in 3.5 :) –  onetrickpony Dec 14 '12 at 2:54
    
Can you show the code you were using? –  brasofilo Dec 14 '12 at 3:59
add comment

1 Answer

if(is_admin() && isset($_GET['taxonomy']) && $_GET['taxonomy'] == 'category' && isset($_GET['tag_ID']) {
    // place your code here
}
share|improve this answer
    
Please explain why that could solve the problem. A code snippet is not an answer. –  toscho Dec 14 '12 at 11:11
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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