| @@ 301-307 (lines=7) @@ | ||
| 298 | // find Etag, and Last-Modified |
|
| 299 | foreach($resp->headers as $h) { |
|
| 300 | // 2003-03-02 - Nicola Asuni (www.tecnick.com) - fixed bug "Undefined offset: 1" |
|
| 301 | if (strpos($h, ": ")) { |
|
| 302 | list($field, $val) = explode(": ", $h, 2); |
|
| 303 | } |
|
| 304 | else { |
|
| 305 | $field = $h; |
|
| 306 | $val = ""; |
|
| 307 | } |
|
| 308 | ||
| 309 | if ( $field == 'ETag' ) { |
|
| 310 | $rss->etag = $val; |
|
| @@ 574-579 (lines=6) @@ | ||
| 571 | else return $this->substr($value,$opt); |
|
| 572 | case 'limit': |
|
| 573 | case 'trim_to': // http://www.movabletype.jp/documentation/appendices/modifiers/trim_to.html |
|
| 574 | if(strpos($opt,'+')!==false) |
|
| 575 | list($len,$str) = explode('+',$opt,2); |
|
| 576 | else { |
|
| 577 | $len = $opt; |
|
| 578 | $str = ''; |
|
| 579 | } |
|
| 580 | if($len==='') $len = 100; |
|
| 581 | if(abs($len) > $this->strlen($value)) $str =''; |
|
| 582 | if(preg_match('/^[1-9][0-9]*$/',$len)) { |
|