dk-list-posts-NEW-EMPLOYEES

‘5’, ‘order’ => ‘DESC’,’post_status’ => ‘publish’, ‘category’ => ’34’);
$recent_posts = wp_get_recent_posts( $args );

//print_r($recent_posts);

foreach( $recent_posts as $recent )
{
echo ‘
Post ID: ‘.$recent[“ID”];
echo ‘
Post URL: ‘.get_permalink($recent[“ID”]);
echo ‘
Post Title: ‘.$recent[“post_title”];
echo ‘
Post Title: ‘.$recent[“post_category”];
//print_r($recent);

//echo ‘
Post Content: ‘.$recent[“post_content”];
//eval($recent[“post_content”]); // ONLY WITHOUT PHP TAGS IN POST!!!

$postid = $recent[“ID”];
echo $post-id;
$acftitle=get_field(“name”, $postid);
echo ‘
The ACF Title: ‘ . $acftitle;
$acfcontent=get_field(“position”, $postid);
echo ‘
The ACF Content: ‘ . $acfcontent;

}
?>

========================================================================
Table for cat 34
========================================================================

Our Newest Arrivals
‘9999’, ‘order’ => ‘DESC’,’post_status’ => ‘publish’, ‘category’ => ’34’);
$recent_posts = wp_get_recent_posts( $args );

foreach( $recent_posts as $recent )
{
if($filler==1){$color=”eee”;$filler=0;}else{$color=”fff”;$filler=1;}
$postid = $recent[“ID”];
$name=get_field(“name”, $postid);
$position=get_field(“position”, $postid);
echo ‘

‘;
//echo ‘

‘;
echo ‘

‘;
echo ‘
‘;
}
?>

Name Position
‘.$name.’ ‘.$recent[“post_title”].’ ‘.$position.’
‘.$name.’ ‘.$position.’
Scroll to Top