Skip to main content

Timeline for Post Meta statement?

Current License: CC BY-SA 4.0

5 events
when toggle format what by license comment
May 11, 2018 at 13:45 vote accept Garrosh
May 11, 2018 at 13:45 comment added Garrosh My bad, I had misplaced the code in my file. thank you again !
May 11, 2018 at 13:42 comment added Jacob Peattie That line was just copied from your code so it shouldn't be behaving any differently. The first argument for get_post_meta() needs to be a post ID. How to get that depends on the context.
May 11, 2018 at 13:38 comment added Garrosh Thank you @Jacob, but I have an error: "Fatal error: Cannot use object of type WP_Post as array". The line is "$type = get_post_meta($post['ID'], 'Type', true);"
May 11, 2018 at 13:32 history answered Jacob Peattie CC BY-SA 4.0