I'm trying to the $appLink variable with a custom field value outside of the loop. I'm using Wurfl to detect the users device, I'd like to echo the custom field value for the URL. This is what I have but I can't get it to work. Can anyone help please?
else if ($os == 'iOS')
{
global $wp_query;
$postid = $wp_query->post->ID;
$appLink = echo get_post_meta($postid, 'ios_app_link_sb', true);
wp_reset_query();
}
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…