Stopped working after custom functions.php for woocommerce
-
Hello,
I was able to drag and drop posts and post tags, but I wanted to also be able to drag and drop Woocommerce Product Tags. To that end, I used some custom code in my functions.php file to try and combine the two types of tags. It did not work and it also killed my ability to reorder regular posts and post tags. I then removed the code from my functions.php file, but still I cannot reorder anything. Any idea how to reset the situation so the plug-in works? Also, is there a way to make the plug-in work for Woocommerce Product Tags?Here is the code I put into functions.php for reference, although it is now deleted.
function custom_wc_add_post_tags( $args ){
$args[‘taxonomies’] = array(‘post_tag’);
return $args;
}
add_filter( ‘woocommerce_register_post_type_product’, ‘custom_wc_add_post_tags’ );add_filter(‘woocommerce_taxonomy_objects_product_tag’, ‘__return_empty_array’);
add_filter(‘woocommerce_taxonomy_args_product_tag’, ‘__return_empty_array’);function custom_wc_remove_product_tags_column($columns){
unset( $columns[‘product_tag’] );
return $columns;
}
add_filter( ‘manage_edit-product_columns’, ‘custom_wc_remove_product_tags_column’, 15 );
- The topic ‘Stopped working after custom functions.php for woocommerce’ is closed to new replies.