PHP code example of ashleyfae / contextwp-sdk

1. Go to this page and download the library: Download ashleyfae/contextwp-sdk library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

ashleyfae / contextwp-sdk example snippets




add_action('contextwp_sdk_loaded', function (\ContextWP\SDK $sdk) {
    $sdk->register(
        (new \ContextWP\ValueObjects\Product('PUBLIC_KEY_HERE', 'PRODUCT_UUID_HERE'))
    );
});

add_action('contextwp_sdk_loaded', function (\ContextWP\SDK $sdk) {
    $sdk->register(
        (new \ContextWP\ValueObjects\Product('PUBLIC_KEY_HERE', 'PRODUCT_UUID_HERE'))
            ->setVersion($yourVersionHere)
    );
});