[wp-trac] [WordPress Trac] #29654: A bug in get_post_meta
WordPress Trac
noreply at wordpress.org
Sat Sep 13 11:25:25 UTC 2014
#29654: A bug in get_post_meta
--------------------------------+------------------------------
Reporter: muhammadfarhanatif | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Options, Meta APIs | Version: 4.0
Severity: normal | Resolution:
Keywords: reporter-feedback | Focuses:
--------------------------------+------------------------------
Changes (by SergeyBiryukov):
* keywords: => reporter-feedback
Old description:
> Respected Sir,
> I hope you are fine & doing great!
> First of all congratulation for given us wordpress 4.0 with great new
> features.
> Currently I am facing issue due to wordpress 4.0 get_post_meta function.
> It is not working fine at my end like this
> $meta_values = get_post_meta( $post_id, $key, $single );
> But it is working fine after this bit of changing in code
> $meta_values = get_post_meta( "$post_id", $key, $single );
> So please let me know where are the issue.I mean issue in wordpress 4.0
> or in codex documentation.
> I hope you will understand my point.
> Thanks & best Regards
> Muhammad Farhan Atif
New description:
Respected Sir,
I hope you are fine & doing great!
First of all congratulation for given us wordpress 4.0 with great new
features.
Currently I am facing issue due to wordpress 4.0 get_post_meta function.
It is not working fine at my end like this
{{{
$meta_values = get_post_meta( $post_id, $key, $single );
}}}
But it is working fine after this bit of changing in code
{{{
$meta_values = get_post_meta( "$post_id", $key, $single );
}}}
So please let me know where are the issue.I mean issue in wordpress 4.0 or
in codex documentation.
I hope you will understand my point.
Thanks & best Regards
Muhammad Farhan Atif
--
Comment:
Could you provide a piece of code to reproduce the issue on a clean
install?
`$post_id` should be an integer, changing it to a numeric string doesn't
make any sense.
I'd suggest trying the [https://wordpress.org/support/ support forums] for
troubleshooting, until the exact bug is identified and confirmed.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/29654#comment:1>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list