Skip to content

Commit

Permalink
Bug #2269272/ #1/ #1486, Fix OU Media Player for intranet-restricted …
Browse files Browse the repository at this point in the history
  • Loading branch information
nfreear committed Nov 20, 2014
1 parent b774d87 commit a5c24c1
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions http.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ protected function _prepare_request($url, $spoof, &$options) {
}


$ua = 'OU Player/0.9 (PHP/cURL)';
$ua = 'OU Player/1.1.* (PHP/cURL)';
if ($spoof) {
// Updated, April 2012.
$ua = "Mozilla/5.0 (Windows NT 6.1) AppleWebKit/535.19 (KHTML, like Gecko) Chrome/18.0.1025.142 Safari/535.19";
Expand Down Expand Up @@ -104,10 +104,11 @@ protected function _http_request_curl($url, $spoof, $options, $result) {
curl_setopt($h_curl, CURLOPT_REFERER, base_url());
}

/*if ($options['cookie']) {
// Required for intranet-restricted content [Bug: #1]
if ($options['cookie']) {
curl_setopt($h_curl, CURLOPT_COOKIE, $options['cookie']);
header('X-Proxy-Cookie: '.$options['cookie']);
}*/
}

if (! $options['ssl_verify']) {
curl_setopt($h_curl, CURLOPT_SSL_VERIFYPEER, FALSE);
Expand Down

0 comments on commit a5c24c1

Please sign in to comment.