Title: Product Reference
Last modified: March 14, 2020

---

# Product Reference

 *  [Flector](https://wordpress.org/support/users/flector/)
 * (@flector)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/product-reference/)
 * 1). Why no option to check “Product Reference” on activation/deactivation action?
   
   Now I use code:
 *     ```
       // check "Product Reference" on the activation/deactivation of a license key
       add_action('slm_api_listener_slm_activate', 'check_license_and_product_on_slm' );
       add_action('slm_api_listener_slm_deactivate', 'check_license_and_product_on_slm' );
       function check_license_and_product_on_slm() {
          if (isset($_REQUEST['item_reference'])) {
             $product_ref = sanitize_text_field(urldecode($_REQUEST['item_reference']));
             $key = trim(strip_tags($_REQUEST['license_key']));
   
             global $wpdb;
             $tbl_name = SLM_TBL_LICENSE_KEYS;
             $sql_prep1 = $wpdb->prepare("SELECT * FROM $tbl_name WHERE license_key = %s", $key);
             $retLic = $wpdb->get_row($sql_prep1, OBJECT);
   
             if ($retLic && $retLic->product_ref != $product_ref) {
                $args = (array('result' => 'error', 'message' => 'Your license key was not issued for this product'));
                SLM_API_Utility::output_api_response($args);
             }
          }
       }
       ```
   
 * Any license code for any product – bad idea.
 * 2). Please change options “Maximum Allowed Domains” and “Manual Reset Count” 
   from “text” to “number”.
 * 3). Please add possibility to unset “Date of Expiry” or set default value.

Viewing 1 replies (of 1 total)

 *  Plugin Support [mbrsolution](https://wordpress.org/support/users/mbrsolution/)
 * (@mbrsolution)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/product-reference/#post-12550281)
 * Hi, thank you for reaching out to us. I have submitted a message to the developers
   to investigate further your request.
 * Thank you

Viewing 1 replies (of 1 total)

The topic ‘Product Reference’ is closed to new replies.

 * ![](https://ps.w.org/software-license-manager/assets/icon-128x128.png?rev=1135848)
 * [Software License Manager](https://wordpress.org/plugins/software-license-manager/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/software-license-manager/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/software-license-manager/)
 * [Active Topics](https://wordpress.org/support/plugin/software-license-manager/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/software-license-manager/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/software-license-manager/reviews/)

 * 1 reply
 * 2 participants
 * Last reply from: [mbrsolution](https://wordpress.org/support/users/mbrsolution/)
 * Last activity: [6 years, 2 months ago](https://wordpress.org/support/topic/product-reference/#post-12550281)
 * Status: not resolved