WP E-Commerce Basics

WP E-commerce is a powerful plugin, but getting started can be a bit messy. Here are some tips.

Go to the checkout page when you click “Add To Cart”

The add-to-cart button uses a javascript to stay on the same page while submitting the product form. To make it go to the checkout page we want to remove the javascript. This can be done by changing the name of the containing element. The javascript effects form.product_form. If you look at the product template you can change the class here:

The other thing you need to change is the action. The default form action is the same page on which the form exists. Change that to the checkout page.

Fix the checkout form

The checkout form can start off pretty messy looking, depending on your containing theme. What I like to do when styling plugins is create a separate stylesheet for the plugin, then call it at the bottom of header.php. That way the styles will override the plugin styles.

The checkout form template is wpsc-shopping_cart_page.php

To edit it copy this to your theme directory. WPEC has a tool that does this for you in Settings — Presentation. Don’t forget to flush the theme cache.

Two carts are displaying on checkout page

Change the shopping cart settings to widget instead of page in presentation.

Checkout page is broken

If there are no address fields showing on the check out page make sure that if “enable shipping” is selected you have valid shipping methods.

Checkout page has break tags in the form fields

Remove line breaks from the label tag. Thanks shivaweb.

Comments are closed.