Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author johnh10

    (@johnh10)

    Currently taxonomies are not supported.

    Thread Starter DengineerPC

    (@dengineerpc)

    Thanks John. Is there a way with some extra code i can replace the category for posts to a custom taxonomy in the lligin code. I just need that particular functionality

    Thread Starter DengineerPC

    (@dengineerpc)

    FYI I found where I can incorporate this, in case any else needs to. In your main php – added the following lines, its hard coded with the values, but the point is there.

    Line starting 568

    $args = array(
    		'posts_per_page' 	=> $aps_batch,
    		'cat' 			=> $aps_cats,
    		'post_type' 		=> $post_types,
    		'ignore_sticky_posts'	=> true,
    		'tax_query' => array(
    		array(
    			'taxonomy' => 'Featured Ad',
    			'field'    => 'slug',
    			'terms'    => 'yes',
    		),
    	),
    	);
    Plugin Author johnh10

    (@johnh10)

    I was just thinking…

    You could use the built in filter hook ‘aps_eligible_query’ to modify the arguments as you wish. So in your theme’s functions.php you would add something like:

    add_action('aps_eligible_query', 'my_aps_changes', 10, 1);
    
    function my_aps_changes( $args ) {
        $args['tax_query'] => array (
    		array(
    			'taxonomy' => 'Featured Ad',
    			'field'    => 'slug',
    			'terms'    => 'yes',
    		),
    	);
        return $args;
    }
Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Using custom taxonomies with custom post types’ is closed to new replies.