芝麻web文件管理V1.00
编辑当前文件:/home/seolotod/critterchoice.com/wp-content/plugins/wp-automatic/metabox_categories.php
Post posts to this category
'name', 'order' => 'ASC', 'hide_empty' => 0 ); foreach ( $post_types as $post_type ) { // Get categories taxononomies $customPostTaxonomies = get_object_taxonomies ( $post_type ); if (count ( $customPostTaxonomies ) > 0) { foreach ( $customPostTaxonomies as $tax ) { // If category list it's items if (is_taxonomy_hierarchical ( $tax )) { $hierarchical_tax = $tax; // for default tax $args = array ( 'hide_empty' => 0, 'taxonomy' => $tax, 'type' => $post_type ); $categories = get_categories ( $args ); $parentCats = array (); $childCats = array (); $orderedCats = array (); // function to display categories // Get parent cats foreach ( $categories as $category ) { if ($category->parent == 0) { $parentCats [] = $category; } else { $childCats [$category->parent] [] = $category; } } // printing foreach ( $parentCats as $parentCat ) { wp_automatic_category ( $parentCat, $childCats, $tax, $post_type, $camp_post_category ); } } // hiracial } // foreach taxonomy } } // foreach post type //default tax if no tax is already saved if( ! isset($camp_general['cg_camp_tax']) || wp_automatic_trim($camp_general['cg_camp_tax']) == '' ){ if(isset($hierarchical_tax) && wp_automatic_trim($hierarchical_tax) != '') $camp_general['cg_camp_tax'] = $hierarchical_tax; } ?>
Press CTRL + category to multiselect
Keyword to category
Keyword|categoryId (one per line)
</textarea>
Check the title as well
Do not check the content
Exact term match (By default, the plugin looks for a word, enable this to check anywhere not required to be a word)
If matches found, ignore fixed chosen categories above
This option will search the content for the keyword and if exists, it will assign the set category to the post
*example if you added "sugar|5" without quotes ,The plugin will check the content and if it contains the keyword "sugar" it will assign the post to the category which id=5
*example 2 if you added "sugar,diet|5,6" without quotes ,The plugin will check the content and if it contains the keyword "sugar" and the keyword "diet" it will assign the post to the category which id=5 and also the category with id=6
*Look at the categories above for the correct numeric id
Tag the posts with specific tags
Tags(one per line)
</textarea>
Randomly pick tags from the box
Number of Tags ?
Set title words as tags
Keyword to tag
Keyword|tag (one per line)
</textarea>
Check the title as well
Do not check the content
This option will search the content for the keyword and if exists, it will tag the post with the set tag
*example if you added "Messi|Sport" without quotes ,The plugin will check the content and if it contains the keyword "Messi" it tag the post with "Sport"
*example2 if you added "Messi,barca|Sport,Barcelona" without quotes ,The plugin will check the content and if it contains the keyword "Messi" && "barca" it tag the post with "Sport" & "Barcelona"
Set custom taxonomy for tags (If you are using a custom post type)
Taxonomy name
Visit the tags page and read the taxonomy value and paste here. for example woo-commerce products tags page link contains "taxonomy=product_tag&post_type=product" then the taxonomy is product_tag