Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- if (isset($_POST['ads_licensekey']) && wp_verify_nonce($_POST['ads_license'], 'ads_setting_action')) {
- $license = $_POST['ads_licensekey'];
- if ($license != '') {
- update_site_option('ads-license', $license);
- $response = wp_remote_post('https://alidropship.com/?rest', array(
- 'method' => 'POST',
- 'body' => array('key' => $license, 'site' => get_bloginfo('url'))
- ));
- if (is_wp_error($response)) {
- $error_message = $response->get_error_message();
- ads_set_alert(__('Could not connection.', 'ads') . ' ' . $error_message);
- } else {
- $foo = json_decode($response['body']);
- .....................................................
- .........................
- .........
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement