document.getElementById('redirect_b').style.display = "block"; redir_url = "http://web.llnw.jp/mchuob/?mediaId=" + media.media_id; } </script> <body> <?php $access_key = "fWs5Zl7o+Ws05caJCUONJtORD/s="; $secret = "kkJkWaU+9vrBiG43nXDulLKgrJg="; $org_id = "3cdb0e0567264e3fbee117a5663df091"; $base_url = "http://api.videoplatform.limelight.com/rest/organizations/{$org_id}/"; $http_method = "post"; $upload_url = "{$base_url}media"; $signed_request = RestRequest::authenticate_request($http_method, $upload_url, $access_key, $secret); class RestRequest { function authenticate_request($http_verb, $resource_url, $access_key, $secret, $params = null) { $parsed_url = parse_url($resource_url); $str_to_sign = strtolower($http_verb . '|' . $parsed_url['host'] . '|' . $parsed_url['path']) . '|'; $url = $resource_url . '?'; if ($params == null) { $params = array(); } if (!array_key_exists('expires', $params)) { $params['expires'] = time() + 300; } $params['access_key'] = $access_key; $keys = array_keys($params);