mirror of
https://github.com/lkddi/nexusphp.git
synced 2026-04-03 14:10:57 +08:00
fix imdb class construct
This commit is contained in:
@@ -272,7 +272,7 @@ $responseBody = $response->getBody();
|
||||
* @constructor imdb
|
||||
* @param string id
|
||||
*/
|
||||
function imdb ($id) {
|
||||
function __construct ($id) {
|
||||
$this->imdb_config();
|
||||
$this->setid($id);
|
||||
//if ($this->storecache && ($this->cache_expire > 0)) $this->purge();
|
||||
@@ -1159,7 +1159,7 @@ $responseBody = $response->getBody();
|
||||
/** Read the config
|
||||
* @constructor imdbsearch
|
||||
*/
|
||||
function imdbsearch() {
|
||||
function __construct() {
|
||||
$this->imdb_config();
|
||||
}
|
||||
|
||||
@@ -1213,7 +1213,6 @@ $responseBody = $response->getBody();
|
||||
if ($header = $be->getResponseHeader("Location")){
|
||||
if (strpos($header,$this->imdbsite."/find?")) {
|
||||
return $this->results($header);
|
||||
break(4);
|
||||
}
|
||||
#--- @moonface variant (not tested)
|
||||
# $idpos = strpos($header, "/Title?") + 7;
|
||||
|
||||
@@ -37,7 +37,7 @@ class imdb_config {
|
||||
* configuration data here.
|
||||
* @constructor imdb_config
|
||||
*/
|
||||
function imdb_config(){
|
||||
function __construct(){
|
||||
// protocol prefix
|
||||
$this->protocol_prefix = "http://";
|
||||
// the imdb server to use.
|
||||
@@ -80,7 +80,7 @@ require_once ("HTTP/Request2.php");
|
||||
|
||||
class IMDB_Request extends HTTP_Request2
|
||||
{
|
||||
function IMDB_Request($url){
|
||||
function __construct($url){
|
||||
parent::__construct($url);
|
||||
if ( PROXY != ""){
|
||||
$this->setConfig(array('proxy_host' => PROXY, 'proxy_port' => PROXY_PORT));
|
||||
|
||||
Reference in New Issue
Block a user