That should do it. You can now use it_exchange( 'product', 'custom' ); in your template files

Step Two: Tell our API that your new tag exists for the Product class

/**
* Extend the product theme api to include new tags
*
* @since 1.0.0
*/
function it_exchange_addon_custom_extend_product_theme_api( $result, $class, $tag ){
// We don't want this happening in the admin
if ( is_admin() )
return;
// We only want to do this if the current class is the product class and the tag is custom
// This means our code will only happen when it_exchange( 'product', 'custom' ) is called.
// If you have multiple tags, you can do all that logic in here as well
if ( 'IT_Theme_API_Product'== $class && 'custom' == $tag ) {
// Include the file with the class
include_once( '/path/to/our/file/with/class/from/step/one.php' );
// Init an object from the class
$IT_Theme_API_Product_Extension_For_Custom = new IT_Theme_API_Product_Extension_For_Custom();
// Return a callback to your function for the tag
$result = array( $IT_Theme_API_Product_Extension_For_Custom, 'custom' );
}
return $result;
}
add_filter( 'it_exchange_theme_api_get_extended_tag_functions', 'it_exchange_addon_custom_extend_product_theme_api', 10, 3 );

Adding a field to the registration form from an add-on

Requires Exchange 1.1.0

This process takes 3 steps:

Adding the template part to the registration form

Creating a template file in your add-on

Registering that template directory with Exchange

Step One: Add the field to the Registration Form’s field array

The registration form is generated by looping through an array of fields and pulling in a template part for each field. Add a filter to your add-on that pulls in the existing fields and adds your custom field to the array:

Conditional check for Exchange pages

To check which Exchange page we're on, you can use the it_exchange_is_page() function.

E.g. when you want to add conditional code to the <head> section of your site, based on which page you're on, add the following code to your active theme'sfunctions.php file, or to a functions.php file in an exchange folder in your active theme.