Wordpress excluding category from pagination the loop

Wordpress excluding category from pagination the loop

Past below code snippet right before loop and change category ID!

WordPress Snippets - 4 years ago

Getting post tags in wordpress

Getting post tags in wordpress

Withing the loop - it will display the post tags $posttags = get_the_tags(); if ($posttags) { foreach($posttags as $tag) {...

WordPress Snippets - 4 years ago

WordPress admin panel custom landing page after login

WordPress admin panel custom landing page after login

Redirect to different landing page after successful login on wordpress admin panel, if user not a super admin. In your...

WordPress Snippets - 5 years ago

Wordpress restrict a specific word from post title?

Wordpress restrict a specific word from post title?

function titleRestrictionFilter($title){ global $post; $title = $post->post_title; $restrictedWord = "forbidden"; if (stristr( $title, $restrictedWord)) wp_die( __('Error: This title is containing...

WordPress Snippets - 6 years ago

Wordpress limit character in the post title

Wordpress limit character in the post title

function titleLimitChar($title){ if(strlen($title) > 55 && !(is_single()) && !(is_page())){ // not in single post page and page. $title = substr($title,0,55)...

WordPress Snippets - 6 years ago

WordPress remove specific categories posts from the Loop

WordPress remove specific categories posts from the Loop

<?php query_posts('cat=-1'); ?> <?php if (have_posts()) : ?> <?php while (have_posts()) : the_post(); ?>         <h3></h3>                  <p><?php the_time('F jS, Y') ?></p>         ...

WordPress Snippets - 6 years ago