lundi 29 décembre 2014

why wont WP_Query work inside a metabox on a custom post type


I'm building a recipe costing plugin (code linked below) and I am adding a metabox to a custom post type edit screen (recipe). In this meta box i want to list p2p connected posts (ingredients) and the meta data for the connected posts. I have successfully done this in a theme template, but now i want to do this inside the admin edit screen.


Can anyone tell me why this isn't working? im still learning and all this looks good to me, am i using WP_Query in the wrong way considering its being used inside a custom post type meta box? any advice or links would be appreciated.


Here is a link to my code that renders the meta box onto the edit screen: line 22 - 96 (i tried to insert the code onto this page but it did not format properly) https://github.com/greataussiepie/foxwarerecipe/blob/master/includes/meta-boxes/class-foxwarerecipe-meta-box-recipe-data.php





Aucun commentaire:

Enregistrer un commentaire