|
@@ 153-167 (lines=15) @@
|
| 150 |
|
|
| 151 |
|
$this->_disconnect($fp); |
| 152 |
|
|
| 153 |
|
if($this->_redirectaddr) |
| 154 |
|
{ |
| 155 |
|
/* url was redirected, check if we've hit the max depth */ |
| 156 |
|
if($this->maxredirs > $this->_redirectdepth) |
| 157 |
|
{ |
| 158 |
|
// only follow redirect if it's on this site, or offsiteok is true |
| 159 |
|
if(preg_match("|^http://".preg_quote($this->host)."|i",$this->_redirectaddr) || $this->offsiteok) |
| 160 |
|
{ |
| 161 |
|
/* follow the redirect */ |
| 162 |
|
$this->_redirectdepth++; |
| 163 |
|
$this->lastredirectaddr=$this->_redirectaddr; |
| 164 |
|
$this->fetch($this->_redirectaddr); |
| 165 |
|
} |
| 166 |
|
} |
| 167 |
|
} |
| 168 |
|
|
| 169 |
|
if($this->_framedepth < $this->maxframes && count($this->_frameurls) > 0) |
| 170 |
|
{ |
|
@@ 212-226 (lines=15) @@
|
| 209 |
|
$this->_httpsrequest($path, $URI, $this->_httpmethod); |
| 210 |
|
} |
| 211 |
|
|
| 212 |
|
if($this->_redirectaddr) |
| 213 |
|
{ |
| 214 |
|
/* url was redirected, check if we've hit the max depth */ |
| 215 |
|
if($this->maxredirs > $this->_redirectdepth) |
| 216 |
|
{ |
| 217 |
|
// only follow redirect if it's on this site, or offsiteok is true |
| 218 |
|
if(preg_match("|^http://".preg_quote($this->host)."|i",$this->_redirectaddr) || $this->offsiteok) |
| 219 |
|
{ |
| 220 |
|
/* follow the redirect */ |
| 221 |
|
$this->_redirectdepth++; |
| 222 |
|
$this->lastredirectaddr=$this->_redirectaddr; |
| 223 |
|
$this->fetch($this->_redirectaddr); |
| 224 |
|
} |
| 225 |
|
} |
| 226 |
|
} |
| 227 |
|
|
| 228 |
|
if($this->_framedepth < $this->maxframes && count($this->_frameurls) > 0) |
| 229 |
|
{ |