Skip to content

Instantly share code, notes, and snippets.

View kontikidigital's full-sized avatar

Kontiki Digital kontikidigital

View GitHub Profile
@kontikidigital
kontikidigital / widget-product-categories.php
Created January 15, 2023 06:12 — forked from doubleedesign/widget-product-categories.php
Override the output of the WooCommerce product categories widget to be a Bootstrap accordion
<?php
/**
* Product Categories Widget
* Modifies the WooCommerce product categories widget to display as a Bootstrap accordion.
*
* @package WooCommerce/Widgets
* @version 2.3.0
*/
defined( 'ABSPATH' ) || exit;
@kontikidigital
kontikidigital / import-if-syntax.md
Created February 17, 2023 09:25 — forked from trey8611/import-if-syntax.md
XPath IF statements

WP All Import - IF/ELSE statement examples

Here are some example WP All Import [IF] statements. The criteria for an IF statment is written in XPath 1.0 syntax and can use XPath functions. Although powerful, XPath syntax can be quite complex. In many cases it might be easier to use a PHP function as shown here.

The [ELSE]<something> part is optional

Number is equal to:

[IF({price[.=0]})]Zero[ELSE]Not Zero[ENDIF]