WC_Products_Tracking::possibly_add_product_import_scripts
Adds the tracking scripts for product setting pages.
Method of the class: WC_Products_Tracking{}
No Hooks.
Returns
null. Nothing (null).
Usage
$WC_Products_Tracking = new WC_Products_Tracking(); $WC_Products_Tracking->possibly_add_product_import_scripts( $hook );
- $hook(string) (required)
- Page hook.
WC_Products_Tracking::possibly_add_product_import_scripts() WC Products Tracking::possibly add product import scripts code WC 11.1.2
public function possibly_add_product_import_scripts( $hook ) {
$product_screen = $this->get_product_screen( $hook );
if ( 'import' !== $product_screen ) {
return;
}
WCAdminAssets::register_script( 'wp-admin-scripts', 'product-import-tracking', false );
}