האתר בבניה
בקרו אותנו בקרוב
מפת אתר
ITEMS: ' . count($terms) . '
'; foreach ( $terms as $term ) { //if(get_field('PageActive',$term)){ echo 'ITEMS: ' . count($subterms) . '
'; $posts = get_posts( array( 'post_type' => ['post'], 'hide_empty' => false, 'posts_per_page' => -1, 'tax_query' => array( array( 'taxonomy' => $term->taxonomy, 'field' => 'term_id', 'terms' => $term->term_id, ) ) ) ); //echo 'subterms:' . count($subterms); //echo '
posts:' . count($posts); //echo '
taxonomy:' . $term->taxonomy; //echo '
terms:' . $term->term_id; if(count($subterms) || count($posts)){ echo '
- ';
if(count($subterms)){
CategoryLooper($term->term_id);
}
if(count($posts)){
foreach ($posts as $post) {
$postcat = get_the_category( $post->ID );
if (! empty( $postcat ) ) {
//echo esc_html( $postcat[0]->name );
if($postcat[0]->name == $term->name){
echo '
- ' . $post->post_title . ''; } } } } echo '
- ";
$pages = get_pages(array('post_type' => 'page','post_status' => 'publish','parent' => 0));
foreach($pages as $page) {
echo '
- ' . get_the_title($page->ID) . '';
$SubPages = get_pages(array('post_type' => 'page','post_status' => 'publish','parent' => $page->ID));
if(count($SubPages)){
echo '
- ';
foreach($SubPages as $SubPage) {
echo '
- ' . get_the_title($SubPage->ID) . ' '; } echo '
';
}
CategoryLooper(0);
echo "