ims_new_order

Description

The “ims_new_order” filter is used to modify order object before is created. The content type must be “ims_order”.

A plugin (or theme) can modify the object with the code:

<?php add_filter( 'ims_new_order', 'filter_function_name'); ?>

The hook is located in the image-store/_inc/cart.php file.

Example

// Apply filter
function modify_ims_new_order( $order, $ImStoreCart  ) {
	$order->title == 'order number: ' $order->ID;
	return $order;
}
add_filter('ims_new_order', 'modify_ims_new_order');

Note:  $order is an object that must match the values returned by get_post(), $ImStoreCart is the global cart object.


Leave a Reply

Your email address will not be published. Required fields are marked *