0
votes
0answers
12 views

Hook on Add new category from post editor [duplicate]

How can I "hook" on Add new category metabox from post editor page? I need to add some default values to DB when adding new category
0
votes
1answer
12 views

Set the default category of an attachment

I wanted to apply the same categories that exist for posts to attachments, so I wrote this code: function wpmediacategory_init() { register_taxonomy_for_object_type( 'category', 'attachment' ); } ...
0
votes
1answer
162 views

what is the action hook code to supporting product category condition in single product page of woocommerce?

I want to display product attributes of 2 different product category with the help of conditional tags. But the condition was not working This is the condition that i given ...
0
votes
1answer
43 views

Hook into create_category

I'm trying to in some way hook into when a new category is created. What I would like to do is to see the term and slug that was created and log them/email them. I have tried to hook in to ...
4
votes
1answer
85 views

Hook when category is added to post

I'm trying to do something when a category is added to post and saved. I thought that using the save_post hook would have registered when a category is added to a post, but it doesn't appear to. When ...
1
vote
1answer
644 views

functions.php conditional tag - only show in single.php?

//Geo Map add_action( 'woo_post_inside_after', 'my_geo_mashup' ); function my_geo_mashup() { global $post; if ( in_category('listings') ) { echo GeoMashup::map(); } } Works to ...
0
votes
2answers
577 views

Categories widget show empty?

Is there a way I can display all categories in the categories widget that comes with wordpress. I do not want to have to edit the core files and I want to stay away from rewriting the widget, but if ...
4
votes
3answers
5k views

add_action hook for completely new post?

publish_post Runs when a post is published, or if it is edited and its status is "published". Action function arguments: post ID. -Plugin API Documentation I've added the publish_post ...
0
votes
1answer
248 views

Which are the hooks run before/after when a category's deletion?

What are the actions that a plugin can hook on to for processing when the user deletes a category?