Hi I can't see in any post here on how to call a Post with Italian, Spanish or English translation. Below is a code that I put on my custom plugin but it calls all languages and translation. How can I specify it to call Italian, English or Spanish?
$sql="SELECT ID,post_excerpt FROM wp_posts WHERE post_status = 'publish' AND post_type = 'postitem' ORDER BY post_date DESC";
$aitem = array();
$posts = $wpdb->get_results($sql);
foreach ($posts as $post){
$aitem[$post->ID] = $post->post_excerpt;
}
thanks TIA