[wp-trac] [WordPress Trac] #42699: WP_Post $post object not properly returning values for meta keys

WordPress Trac noreply at wordpress.org
Sun Nov 26 02:26:44 UTC 2017


#42699: WP_Post $post object not properly returning values for meta keys
--------------------------------+------------------------------
 Reporter:  saiu                |       Owner:
     Type:  defect (bug)        |      Status:  new
 Priority:  normal              |   Milestone:  Awaiting Review
Component:  Options, Meta APIs  |     Version:  4.9
 Severity:  normal              |  Resolution:
 Keywords:                      |     Focuses:
--------------------------------+------------------------------

Comment (by dd32):

 It sounds like you've got a bug in some custom code somewhere, perhaps
 something overwriting the global `$post` object, perhaps in the template
 you're pulling in.

 `var_dump( $post )` where you're having the issue, look at the value, and
 backtrace up the pageview until you find where it's a WP_Post object, then
 investigate all functions inbetween, should get you to the source of your
 problem.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/42699#comment:8>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list