Checkout: Products Search Widget

[wpdocsparentlink]
The products search widget is a simple search box which can be used by your users/customers to search for products in your shop by keyword/phrase.

The plugin uses the “Shop Front Page” page to perform the products search on so go to Checkout > Configuration > Posts/Pages and Categories Settings in the plugin and ensure that you specified a page containing [wpcoproducts] in it for the “Shop Front Page” setting.

Configure the products search widget

First you must go to the Appearance > Widgets section in your WordPress dashboard where you will drag a Checkout widget to your sidebar(s).

2015-08-12_15-10-49

You can then fill in a title/heading for the products search widget and be sure to select “Products Search Widget” for the “Display:” option.

Front-end Display

2015-08-12_15-11-03

Hardcode the products search widget

You can hardcode the products search widget directly into your WordPress theme with the following PHP code:

<?php if (class_exists('wpCheckout')) : ?>
    <?php $wpCheckout = new wpCheckout(); ?>
    <?php $wpCheckout -> widget('search'); ?>
<?php endif; ?>

Here is the code: http://tribulant.pastebin.com/YYNuQe3S

Beautiful Newsletter Templates

Professional newsletter templates that are fully responsive for desktop, tablet and mobile. They are 100% cross-client compatible.

See Them

Pin It on Pinterest

%d bloggers like this: