May 22, 2008 in Web Design News, Wordpress News

WP Ecommerce Template Tags


A growing list off all the template tags you can use to design and customize wp ecommerce, The plugin is still in its infancy and documentation is a little sparse but its a great ecommerce plugin for adding a shop to WordPress.

Display Shopping Cart

Description

The template tag nzshpcrt_shopping_basket displays the shopping cart, usually used to add the cart to the sidebar or header.

Usage

< ?php echo nzshpcrt_shopping_basket(); ?>

Display Category or Brand

Description

The template tag show_cats_brands displays a list of the categories and brands. Usually used to list all the categories in a sidebar

Usage

<?php show_cats_brands(); ? >

Display Products from a Category

Description

The template tag wpsc_category displays a list of the products from a specified category. Usually used to create category pages.

Usage

[wpsc_category=2, full ]

Display Default Products

Description

The template tag productspage displays a list of the products from your default category, you set your default category in shop settings.

Usage

[ productspage ]

Display Homepage Products

Description

The template tag homepage_products displays a list of the products you set if “display on frontpage” is ticked for each individual product. Usually used for you shop homepage.

Usage

[homepage_products ]


About Anthony

Anthony Brewitt is Design Bit, has been for years - he's an experienced WordPress Designer, and Muggle-born Marketing Philosopher. Let’s talk about your website; your marketing, blog design, and that cool new mobile web thingy. Contact Anthony

39 Responses to WP Ecommerce Template Tags

  1. Can you give a link to a store or two using this?

  2. I have sent a list for you Mike, you can find an updated list on Instincts Website.

  3. Tony

    Where on the Instincts Website? .. and none of these even appear to work on 3.6.5

  4. [wpsc_category=2, full ] does not work for 3.6.6 in my install.

    http://gabrielbeach.com/products-page

  5. I take it all back. I copied and pasted which left me with a space between the text ‘full’ and the bracket. Watch out for that!

  6. Pingback: Setting up an e-commerce site with Wordpress and WP e-commerce « Ikool’s Blogbed

  7. Josh

    T-H-A-N-K you for this. I’ve looked everywhere but the moon for how to set up a page with all of the products listed. The homepage_products answer is great. I have a permalink question. My permalinks are set to /%year%/%postname%/ . To get individual product pages to work, I was creating individual product pages under this structure, and then redirecting them to this: ?product_id=123. Then I upgraded to the newest e-commerce plugin and can’t find a way to get to individual product pages. I’d like to put some of the gold modules that I purchased to use, but I can’t do it if I can’t link anything to individual product pages. Any advice would be greatly appreciated.

  8. Firstly, I would post this on the Instinct Forum, then others can learn from your problem too. Ive emailed you Josh.

  9. WP e-commerce is in its infancy for a very long time. I use YAK.
    It works great for my site. There were no such tags to implement, because Yak uses WordPress native pages and posts to publish products.

  10. Jairus

    Is there a way to list -all- the products, alphabetically?

  11. We’re very excited to release the WP ECommerce Bible. Check it out…

    http://www.wpecommercebible.com

  12. New WP e-Commerce Coming Soon

    WP e-Commerce as a plugin is not in its infancy – WP e-Commerce 3.6.7 is about to be released and it is about to blow your mind.

    It comes with serious e-commerce features for people that want a serious e-commerce solution. If you want to throw up an image with a price in a page or a post then by all means use YAk.

    But if you want the real deal then WP e-Commerce is built on years of e-Commerce knowledge and has plenty of important features for people wanting to SELL Online – such as the ability to interface with many payment gateways, the ability to interface with shipping companies, and much much more…

    The documentation that has been in its infancy is no longer in its infancy. WP e-Commerce is the only plugin with a book. WP e-Commerce has new fourms and I’m in the process of writing more doucmenation at the moment.

    Anyway thanks to Anthony for posting this list.

    I’ll be updating the list of tags as soon as possible. We’ve added a few more that should hopefully be added to 3.6.7

    Template tags are very important because they let you put things like the ‘goto checkout button’, or the ‘shopping cart’, or the category list anywhere in your WordPress template… these are the types of things that give you freedom baby!!

    Ciao,

    Dan

  13. I appreciate the work Instinct are putting into this product and am a user myself. But as an experienced e-commerce designer I’m afraid the documentation is still lacking in detail and form and a simple list of template tags is still not available (Instinct,feel free to copy and paste mine).

    The wp-ecommerce bible seems it has been rushed, which is not acceptable given it costs money and the documentation designers really need is still unavailable.

    I’ll be giving 3.6 a full review soon but can report that the accessibility is poor and we still do not validate transitional XHTML, never mind strict XHTML, also its still reliant on Javascript for core functionality- which as we all know should act as an extra behavioral layer on top of functional PHP. Semantically it still fails with tables doing alot of the layout work.

    But its still the best WordPress shopping cart and most e-commerce carts also rubbish web standards.

  14. Hi Anthony. Thanks for such a prompt reply.

    Tomorrow we will be replacing all the tables for divs and releasing WP e-Commerce 3.6.7

    Sometime probably the end of next week we aim to release a fully Semantic version.

    If you have any ideas for tags let me know. You have my email address – funnily enough as I’ve been writing the documentation I have been coming up with all sorts of things I’d like to see made into tags….

    Any code volunteers 😉

    Ciao,… Dan

  15. @Dan, I’ll email you today, I have some ideas for tags. Very glad to hear about the semantic version, I’ll hold off my full review until its ready. With the features and better quality coding in place it sounds like this next version will be a milestone indeed.

  16. Josh

    Does anybody have any statistics on how this plugin affects conversion? Or are we just talking about aesthetic ‘milestones’?

  17. I have a new project that involves WP Ecommerce plugin, and I must say that you guide helped me a lot.

    Thanks.

  18. Nice and just bookmark it. Thank you

  19. For a truly professional ecommerce solution for WordPress go to http://tribulant.com

    Blows this frustrating plugin out of the water.

    I spent over a year trying to get this instinct plugin to work and every upgrade brought with it more “features” and less stability.

    Save yourself some time and tears and swing over to http://tribulant.com

  20. Pingback: One-Theme static site with wp e-commerce shopping cart? - One Theme Support Forums

  21. jj

    I’ve found a solution.
    put a textfile called php.ini with the following line into the wp-admin folder:
    memory=20MB

    should work fine. btw I am running on WordPress 2.7

  22. i use wp e-commerce and i want to show list of latest products in a post or page? can u help with the code? php code

    thx

  23. Your info has helped me to manage my shop. thank u

  24. Hi Anthony,

    I was just wondering if you knew of a php tag to display a list of categories instead of products? Im looking to have images for categories and then click through to view images of sub-categories and then click through to products within that category, if that makes sense!

    Thanks

  25. Pingback: Web Design Blog » WP Ecommerce Template Tags - Designbit - Blog Design, Web Design, Wordpress and Shopify Blog | Squico

  26. I need to show only the number of products in the cart not the entire cart .how is it possible.

  27. Pingback: Web Design Blog » WP Ecommerce Template Tags – Designbit – Blog Design, Web Design, Wordpress and Shopify Blog | WordPress News

  28. Many times I have been googling for information of this topic, never found a real source before now, how cool is that, thanks.

  29. Thanks for posting, it was very handy and helped me quite a bit

  30. 6. Very nice post. I just stumbled upon your weblog and wanted to say that I have really enjoyed browsing your blog posts. After all I will be subscribing to your rss feed and I hope you write again soon!

  31. Aakash Niit Jcs

    how to add, remove and edit a product with wp-ecommerce. Please tell me the functions and codes.

  32. Fabian

    is there a way to use shortcodes in theme editor? or: what is the template tag for those shortcodes?

  33. Fabian

    can’t edit.

    i mean: how to display the variables in the template tag
    [wpsc_category=2, full ]
    ??

    thx

  34. Fabian

    omg.. deleting php

    ??

    (sorry for double and tripple post!)

  35. Fabian

    -.-

    wpsc_category(2, full) ?

  36. Exactly what I was looking for…thanks! Now if I can find a way to load custom sidebars on the page…that would be awesome! For some reason my wp-ecommerce page uses the “default page template” not allowing me to use a page template that uses a custom sidebar

  37. Madhuri

    oops!!! its not working

  38. Pingback: WP Ecommerce Template Tags | elojasmais

  39. Vandhana Mtech

    i want to get a products on home page im using the wp-ecommerce plugin

Leave a Reply