I'm trying to use a jquery toggle shortcode in a theme template.
The shortcode goes like this:
[sws_toggle3 title="Title"]You can now see the displayed text.[/sws_toggle3]
I want to pull posts from a specific category and use the toggle to display them in the page.
This is what my theme template currently has:
<?php $wp_query->query('cat=11&paged=' . $paged); while ($wp_query->have_posts()) : $wp_query->the_post();?> <li id="post-<?php the_ID(); ?>"> <h2><a class="title" href="<?php the_permalink(); ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2> <div class="post"> <?php the_content(); ?> </div> <div class="clear"></div> </li> <?php endwhile; ?>
With the output being something like:
[sws_toggle3 title="<?php the_title(); ?>"]<?php the_content(); ?>[/sws_toggle3]
Is this possible? Any help would be much appreciated.
Thanks