true), 'names');
// Each post types
foreach ($visiblePostTypes as $post_type){
// skip
if($post_type == "snp_popups"){
continue;
}
// query for your post type
$query = new WP_Query(
array(
'post_type' => $post_type,
'posts_per_page' => -1
)
);
if ( $query->have_posts() ) {
// Has Single Style?
$hasTemplate = "0";
// this type template
$templateStyle = get_option('wt_'.$post_type.'_css');
// check post meta
if(empty($templateStyle) != true && $templateStyle != "false"){
$hasTemplate = substr_count($templateStyle, ';');
}
// show an label
echo '
'.ucfirst($post_type).'
';
// Each lists
while ( $query->have_posts() ) {
$query->the_post();
$title = get_the_title();
$id = get_the_id();
$infor = "";
if($id == $frontpage_id){
$infor = "Front Page";
}else if($id == $blogpage_id){
$infor = "Posts Page";
}
// check the style
$hasStyle = "";
// Has Single Style?
$hasSingle = "0";
// with post meta
$get_post_meta = get_post_meta($id, '_wt_css', true);
// check post meta
if(empty($get_post_meta) != true && $get_post_meta != "false"){
$hasStyle = "class='has-style'";
$hasSingle = substr_count($get_post_meta, ';');
}
echo '