Skip to content

Commit

Permalink
Update parse.php
Browse files Browse the repository at this point in the history
修复最后一篇文章标题错误的情况
  • Loading branch information
52fhy authored Dec 2, 2017
1 parent f8b8b9b commit fa8183f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion parse.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
use Overtrue\Pinyin\Pinyin;
$pinyin = new Pinyin(); // 默认

preg_match_all('/<title>(.*)<\/title>.*<link>(.*)<\/link>.*<pubDate>(.*)<\/pubDate>.*<description>(.*)<\/description>/sU', $html, $data, PREG_SET_ORDER );
preg_match_all('/<item><title>(.*)<\/title>.*<link>(.*)<\/link>.*<pubDate>(.*)<\/pubDate>.*<description>(.*)<\/description><\/item>/sU', $html, $data, PREG_SET_ORDER );

// var_dump($data);

Expand Down

0 comments on commit fa8183f

Please sign in to comment.