$_SESSION['ClientInfo'] = $_REQUEST["clientinfo"];
$_SESSION['Platform'] = $_REQUEST["platform"];
$_SESSION['ContentType'] = $_REQUEST["contenttype"];
$_SESSION['ProductID'] = $_REQUEST["yourproductid"];
$_SESSION['RightsID'] = $_REQUEST["rightsid"];
$_SESSION['Version'] = $_REQUEST["version"];
$_SESSION['Return_URL'] = $_REQUEST["return_url"];

Then in the code, you can see the use of wp_get_current_user() to obtain the user’s login information to determine whether the user has logged in to the website. If the user has already logged in to the website, it is directed to login.php for the next step of verification. If the login expires or there is no login to the website, it will Prompt the user to log in to the website again.

Login.php is mainly used to verify whether the user has registered for the current course and get the validity period of the current course. Then call the DRM-X 4.0 interface to perform user detection, update Rights, and obtain licenses.

We have added detailed comments in login.php, you can add or modify the code according to your business model and needs.

When all verifications are passed, it will be directed to licstore.php, please do not modify the file name of licstore.php.

In the licstore.php file, we only did two things.
1. Storage License
To store the license, you only need to output the license under the tag.
echo $license;
?>

2. Determine whether the license has an error message

if(stripos($license, '