Custom Post Types With Cart Ninja

Creating a Custom Post Type

If you are a Wordpress Theme Developer you might be glad to know that Cart Ninja fully supports Custom Post Types. Custom Post Types are a great way to improve your workflow, and if you are creating a website for a client it can help make things more intuitive for them.

Creating a Custom Post Type

I usually use the "Types" Wordpress plugin when creating a custom post type, it's also possible to use the function.php file. In this example i'll use the Types Wordpress Plugin to make a Custom Post Type named "Products"

So I created a new Custom Post Type Named "Products", make sure that you enable the "custom fields" option as this is what allows Cart Ninja to associate this product with the Cart Ninja Product Details.

Cart Ninja Will then show up in the "Products" Custom Post Type:

Theming a Custom Post Type

It's possible to create a custom theme for your post type (by default it uses the theme from index.php or single.php), in this example if you create a new file called single-products.php (because the slug name is products) anything in that file will show up for posts made with that Custom Post Type.

Similary you can create themes for the Post Type Loop, (or Categories for a Custom Post Type). All of that is covered in the Wordpress Documentation.