Skip to main content
12 events
when toggle format what by license comment
Sep 9, 2016 at 17:13 comment added Malisa The way I see that is this piece of code is registering a taxonomy to pages called ''taxonomy'=>'page_category'' and not category. hence the issue of why none of the core WP functions is working. Shouldnt do this here as this is dragging on.. but I would simply use the following to register category tax to pages. then it will work.: add_action('admin_init', 'reg_tax'); function reg_tax() { register_taxonomy_for_object_type('category', 'page'); add_post_type_support('page', 'category'); }
Sep 9, 2016 at 17:08 comment added File_Submit Look what I've found: codeshare.io/K7foR Look for page_category. Hope it helps for the array ()
Sep 9, 2016 at 16:46 comment added Malisa Then there lies the problem,it would seem the plugin or code you have used to add categories to pages, isnt woking correctly. You should get an output of the term associated with the page OR post
Sep 9, 2016 at 16:40 comment added File_Submit It says Array ( ) - nothing else. but on Post (not Page) I've got a bunch of keys in the array
Sep 9, 2016 at 16:37 comment added Malisa No, I meant how are you getting the categories taxonomy onto your pages? Plugin, add_action? Can you put this in your footer and see whats printed out? $term_id = get_the_category( $post->ID ); print_r($term_id);
Sep 9, 2016 at 16:28 comment added File_Submit Like this: infinit.io/_/3mhuJst.png
Sep 9, 2016 at 16:25 comment added Malisa Then sorry to say, I'm stumped.. just a quick question, should have asked you long ago.. how are you adding the category to the page?
Sep 9, 2016 at 16:11 comment added File_Submit I'm sorry to tell, but still not working :/
Sep 9, 2016 at 16:03 comment added Malisa @File_Submit, me rushing, sorry.. should work fine now ..
Sep 9, 2016 at 16:03 history edited Malisa CC BY-SA 3.0
Corrected code, rushing too much
Sep 9, 2016 at 15:54 comment added File_Submit This time we have the meta tag on every page and post. It doesn't appear only on category 92, but on all pages of the site. :S
Sep 9, 2016 at 15:46 history answered Malisa CC BY-SA 3.0