Stratix Flow Blog
Insights & Strategies for Digital Growth
Expert tips on Google Ads, SEO, social media marketing, and web development to help your business thrive online.
All Posts
'count',
'order' => 'DESC',
'hide_empty' => true,
));
foreach ($categories as $cat) :
$cat_active = ($current_category === $cat->slug) ? 'active' : '';
$cat_url = add_query_arg('category', $cat->slug, $blog_page_url);
if ($current_search) {
$cat_url = add_query_arg('s', $current_search, $cat_url);
}
?>
name); ?>
count; ?>
Search: ""
Category: name : $current_category); ?>
'post',
'post_status' => 'publish',
'posts_per_page' => -1,
'fields' => 'ids',
);
if ($current_search) $count_args['s'] = $current_search;
if ($current_category) {
$count_args['tax_query'] = array(array(
'taxonomy' => 'category',
'field' => 'slug',
'terms' => $current_category,
));
}
$count_query = new WP_Query($count_args);
?>
found_posts; ?> results found
'post',
'post_status' => 'publish',
'posts_per_page' => 9,
'paged' => $paged,
'orderby' => 'date',
'order' => 'DESC',
);
if ($current_search) {
$args['s'] = $current_search;
}
if ($current_category) {
$args['tax_query'] = array(
array(
'taxonomy' => 'category',
'field' => 'slug',
'terms' => $current_category,
),
);
}
$blog_query = new WP_Query($args);
$post_index = 0;
if ($blog_query->have_posts()) :
while ($blog_query->have_posts()) : $blog_query->the_post();
$post_index++;
$is_featured = ($post_index === 1 && $paged == 1 && !$current_search && !$current_category);
$categories = get_the_category();
$cat_name = !empty($categories) ? $categories[0]->name : 'Uncategorized';
$cat_link = !empty($categories) ? get_category_link($categories[0]->term_id) : '#';
$author_name = get_the_author();
$author_initial = strtoupper(substr($author_name, 0, 1));
$read_time = max(1, ceil(str_word_count(get_the_content()) / 250));
?>
Featured
No Posts Found
We couldn't find any posts matching your search. Try different keywords or browse all articles.
View All Posts