Good Looking Product Photos for WordPress Shopping Cart Plugin

The best WordPress Shopping Cart Plugin available to date is definitely the one from Instinct Entertainment. The shopping cart comes with 3 free themes and each is ready to be customized extensively.
I know there have been some browser problems with some of the themes but I think they have been worked out.

You can choose from several low cost modules to add on to the free version of the shopping cart plugin in order to have a gallery of multiple images under the main product photo, amongst other cool extras.

When it comes to the main product photo, the one you upload first when adding a new product, you may have experienced some difficulty with the way the resulting thumbnail image is cropped and re sized after uploading. This is the most important picture because its the one customers will see first. It’s been my experience that all product photos turn out the best if shot against a white background with an equal amount of empty space around the item at the top, sides and bottom.You’re going to really want to strive for uniformity because more often than not your product pages are going to show more than one product at a time.

Take a look at these 2 pictures:

goodtoo closely cropped

You can see in the 1st photo there is enough space around the product to result in a nicely resized thumbnail image. But the second photo will get chopped off because there’s not enough space around the product.

This is a screen shot of a row of products with photos that all had the same amount of white space:

a neat row of pictures
ex.1

In the second screen shot, the 1st product photo in the row shows what happens when there is too much space at the top of the model’s head and not enough at the bottom of her feet. And because the other photos in the same row have different cropping and background colors, this row does not look as neat and clean as the first.

a not so neat row
ex.2

Many online customers judge an ecommerce website’s “trustability” by how professional it looks. So spending a little extra time on your product photos will pay off with professional-looking product pages.

HTTPS for the Checkout Page in WordPress Ecommerce

Using this plugin Admin-SSL.
Don’t be surprised if you can’t find this plugin’s config page. It gets installed in the Plugins menu after you activate it. You can switch it to be in the Settings menu but after you find it! Yeah, yeah, yeah, I know but whatever this plugin works!

Securing the Checkout Page
Go to http://yoursite.com/your wordpress folder/wp-admin/options-general.php?page=admin-ssl-config.
Use the Additional URLs box to put in the your order/checkout page. If you aren’t using(or can’t) use permalinks your URL might look like this: ?page_id=12. Except it won’t be 12, it will be the number id that your order/checkout page is. I was so used to being able to use custom permalinks that I was a bit lost when faced with what part of the URL goes there when I came across another server that had not set up mod_rewrite properly.

You can also change the location of your shoppingcart URL to https in Ecommerce>>Settings>>Admin but you will still need this plugin to convert all the URLs to https otherwise your little lock icon will be broken and the addressbar will not turn blue or green if you have spent the big $$$ for an extended SSL. These days online shoppers are warned over and over not to submit credit card numbers on non secure websites. So even if you have purchased and installed your own private SSL certificate and your web page is secure it won’t look like it with a broken lock icon!

I tried using the https-for-wordpress plugin – but you could remove the “s” and still view the order page. Admin-SSL will redirect back to https no matter what and only yhe pages you want to use https will use https. Even though any file or link URL in the document or on the page are auto converted to https, once a site visitor follows any of these links they are redirected back to http. Https-for-wordpress also was not able to convert every link from http to https, namely some files called by plugins in the header theme file.

You can translate trust into sales so it’s a good idea to spring for a proper SSL certificate if you plan on collecting CC numbers anywhere on your site.
The author of this plugin says it can be used for Shared SSL as well.

Revised Fake Grid View

Updated April 19th 2009

If you are using the latest version of the WordPress Shopping Cart plugin, version 3.12.6, please read my latest post on the subject:
“Revised File for Fake Grid View”
The following post is helpful but the file to be downloaded was written for version 3.6.7.

I use wpsc when I mean WordPress Shopping Cart.
Here is a re write of an earlier post on “faking” Grid View(for wordpress shopping cart plugin).
My earlier post did not take into account, beyond styling the page with CSS, the functions in homepage_products_functions.php and how the output of this file varies from the real grid view product display.
So if you have purchased Grid View you should be able to use the Cart Icon button in the Post or Page editor to insert a wpsc category into a Post or Page and have it display just like Grid View,right? I thought so. But it doesn’t work that way.Inserting a single category into a page results in a page that looks a lot like grid view but acts quite differently.

Some key differences between using homepage_products and the grid view
Inserting a wpsc category into a Page(shortcode is for homepage_products) displays a thumbnail gallery of all products from one category and their product titles. If you use “Full” your page will not look like Grid View. If you don’t select Full you will get close to faking Grid View ( if you have the correct CSS to do so). But a Fake Grid View page has one little problem:the thumbnail image does not link to the single product display page(like in Grid View).Instead,it links to the thumbnail image.Which means a thumbnail image will pop up where a full size image should.
Continue reading Revised Fake Grid View

Invalid argument foreach() error in WordPress Shopping Cart Plugin

my cart iconFor the longest time I held off upgrading any of my client’s stores using WP-Shopping Cart plugin because on my test install of WP I could not get RC1 3.6.8 to work.But it really bothers me not to use the latest version of something so on one client site I did the upgrade and tested it out.I got the same exact errors I got on my test install after trying to checkout/submit and have the payment sent to PayPal.

The old invalid argument foreach() error.

Going to the forum I did not see a way to fix this probably because everyone has different causes for this error? I’m not really sure but there should be definite documentation on how to get rid of so people can have a working cart.

Error Log Messages
This error:
WordPress database error Unknown column ‘files’ in ‘field list’ for query INSERT INTO `wp_cart_contents` ( `prodid` , `purchaseid`, `price`, `pnp`, `gst`, `quantity`, `donation`, `no_shipping`, `files` ) VALUES (’18’, ’75’,’64.50′,’0′, ‘0’,’1′, ‘0’, ‘1’, ”) made by nzshpcrt_submit_checkout

Led to this error:

PHP Warning: Invalid argument supplied for foreach() in /xxx/web10/xxxx/pow.xxxl/htdocs/site/wp-content/plugins/wp-shopping-cart/merchants/paypal_multiple.php on line 82

And this all led to the cart being empty and the logs printing the price as 0.00. If the cart can’t put the order into the wp_cart_contents table it can’t process the order. Not being able to fill in the info leads to a PHP error.

Let’s look at this message again:
WordPress database error Unknown column ‘files’ in ‘field list’ for query INSERT INTO `wp_cart_contents` ( `prodid` , `purchaseid`, `price`, `pnp`, `gst`, `quantity`, `donation`, `no_shipping`, `files` ) VALUES (’18’, ’75’,’64.50′,’0′, ‘0’,’1′, ‘0’, ‘1’, ”) made by nzshpcrt_submit_checkout

Everyone of those fields has to be in the wp_cart_contents table in your WP database.If your cart works perfectly all the way up to trying to test if orders can be processed- chances are when you upgraded a field or 2 even were not created.This can happen to WP upgrades as well.It is not a failing of the cart plugin.The fact that some people have no problem upgrading anything speaks to this.

The wp_cart_contents table.
——————-Type——– –Collation — —-Attributes— — — —Null—- — Default
purchaseid—–bigint(20) ——– —– — -UNSIGNED— – — — -No—— ——0
prodid—— – bigint(20) —– —— — — -UNSIGNED– — — –No—— ——0

——————Type———- —–Collation——- —-Attributes— ——Null——-Default
price——-varchar(128)——–latin1_swedish_ci ————– ——–No———-0
pnp———varchar(128)——–latin1_swedish_ci ——– — —– —-No———-0
gst ———varchar(128)——–latin1_swedish_ci ——- ——— – — No———0
quantity– –int(10)———————————— -UNSIGNED— — No ———-0
donation– -varchar(1) ——— latin1_swedish_ci—- —— — —— No ———0
no_shipping – varchar(1)——–latin1_swedish_ci ——— —- — — – No ———- 0
files ——- —text—————-latin1_swedish_ci——— —— — — No ———-

I know it isn’t really a table but it will have to do.

Fixing It
First check your error logs. It’s good to check your error logs the very first sign of trouble. If you can see the same kind of errors that I printed here you are having the same problem I was: field files was not added to the wp_cart_contents table when I upgraded. How pesky.

1st, log into your control panel find Manage Mysql and when you are in the manage mysql area, click on Administer for your WordPress database.

When you are in, look in the left side panel for wp_cart_contents. Click on it.

Please check to see if a “files” line has been added after the no_shipping line in wp_cart_contents.
If not, don’t be scared. It is easy-peasy to add a field to a database table.If the field called files is already there your problem is being caused by something else.Check the table for missing fields you can use my ugly “graph” up above.There should be 9 fields.If anyone of these fields is missing from the table you are going to get the invalid argument foreach() error.

If the field for “files” was not added – no_shipping will be the last field in this table.It was for me.

Look for this option it’s usually underneath the bottom of the table (my host uses phpMyAdmin some other managers will be set up differently).

Add 1 field(s) At End of Table.

Leave the 1 field to be added. Leave the radio button for At End of Table selected.

Then look for the go button-Click go.

In the Field text box, type files and use all use lowercase.

In VARCHAR dropdown list, select TEXT.

Leave everything else alone and click the save button.It’s very important to save it or the field will not get added.

Test it Out!
You should now be able to add an item to the cart and checkout and send the payment to PayPal with no more errors and blank orders in the purchase logs,

if all your checkout and payment settings in the admin for the plugin are correct and there aren’t any other issues with the plugin besides the ones I have written about.