WordPress.org

Support

Support » Plugins and Hacks » WP ECommerce query

WP ECommerce query

  • I’m querying through wpsc_start_category_query and then I want to get only one product from quered product.

    like:
    query category
    category1
    query product by category1
    product1
    query category
    category2
    query product by category2
    and etc..

    <?php wpsc_start_category_query(array(‘category_group’=> get_option(‘wpsc_default_category’), ‘show_thumbnails’=> 1)); ?>
    $args = array(
    ‘wpsc_product_category’ => ‘HERESOMECODE’,
    ‘showposts’ => 1,
    ‘numberposts’ => 1,
    ‘post_status’ => ‘publish’,
    ‘post_type’ => ‘wpsc-product’
    );
    $cat1_posts = get_posts($args);
    ?>

    my problem is that I can’t give ‘wpsc_product_category’ => wpsc_category_name();

    any suggestions?
    really easy task and I really broke my brain

  • The topic ‘WP ECommerce query’ is closed to new replies.