Create wpsc category loop

Starts loop to show all or selected categories.

1) Show default category

 PHP |  copy code |? 
1
<?php wpsc_start_category_query(array('category_group'=>get_option('wpsc_default_category'), 'show_thumbnails'=> get_option('show_category_thumbnails'))); ?>

2) Show all categories

 PHP |  copy code |? 
1
wpsc_start_category_query(array('category_group'=>1,'show_thumbnails'=>get_option('show_category_thumbnails')));

Do some stuff here with the category data.

End the loop.

 PHP |  copy code |? 
1
<?php wpsc_end_category_query(); ?>

This entry was posted in WP Ecommerce. Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>