• crushwaves

    (@crushwaves)


    Have no idea why this isnt working

    <?php
    	if ( is_home() ){
    	$args=array(
    			'showposts'=> (int) get_option('inreview_homepage_posts'),
    			'category_name' => <?php echo do_shortcode('[mmjs-city]') ?>
    		);
    		query_posts($args);
    	}
    ?>

Viewing 2 replies - 1 through 2 (of 2 total)
  • Moderator Jan Dembowski

    (@jdembowski)

    Forum Moderator and Brute Squad

    Is that code within a loop? Many plugins just don’t work unless it’s inside a loop such as within the_content.

    Can you provide the pastebin.com link to more of the code?

    Michael

    (@alchymyth)

    don’t use the php tags within a string section already within php;

    try to replace the one line with:

    'category_name' => do_shortcode('[mmjs-city]')
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Displaying short code in template php’ is closed to new replies.