Get Post Meta in conditional Tag
-
Hi, I am trying to create a fribie section of my website.
And I want to automatically insert after each post and I succeeded. It display different message when user is logged and when user is not logged on the category that I want it to display,
the only problem that I am facing is when getting the post meta work. I always got string error, unexpected when using this line:
$freebielink = get_post_meta($post->ID, 'freebielink', true);
Here’s my working code:
http://pastebin.com/YTzNG3RKI also include
global $post;
above the if statement
- The topic ‘Get Post Meta in conditional Tag’ is closed to new replies.