add_product_meta

Add_product_meta function.

Description

add_product_meta( (mixed) $product_id, (mixed) $key, (mixed) $value, (constant) $unique = false, (bool) $custom = false ); 

Parameters (5)

0. $product_id (mixed)
The product id.
1. $key (mixed)
The key.
2. $value (mixed)
The value.
3. $unique — Optional. (constant) => false
The unique.
4. $custom — Optional. (bool) => false
The custom.

Usage

  1. if ( !function_exists( 'add_product_meta' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'wp-ecommerce/wpsc-includes/meta.functions.php'; 
  3.  
  4. // The product id. 
  5. $product_id = null; 
  6.  
  7. // The key. 
  8. $key = null; 
  9.  
  10. // The value. 
  11. $value = null; 
  12.  
  13. // The unique. 
  14. $unique = false; 
  15.  
  16. // The custom. 
  17. $custom = false; 
  18.  
  19. // NOTICE! Understand what this does before running. 
  20. $result = add_product_meta($product_id, $key, $value, $unique, $custom); 
  21.  

Defined (1)

The function is defined in the following location(s).

/wpsc-includes/meta.functions.php