Commit | Line | Data |
---|---|---|
1 | <?php | |
2 | error_reporting(0); | |
3 | // include lastRSS library | |
4 | include './lastRSS.php'; | |
5 | ||
6 | // create lastRSS object | |
7 | $rss = new lastRSS; | |
8 | ||
9 | // setup transparent cache | |
10 | $rss->cache_dir = './cache'; | |
11 | $rss->cache_time = 3600; // one hour | |
12 | ||
13 | // load some RSS file | |
14 | // XXX | |
15 | if ($rs = $rss->get('http://h-k.sk/scripts/google2rss.php?num=15&q=smallpox')) { | |
16 | ||
17 | print_r($rs); | |
18 | } | |
19 | else { | |
20 | die ('Error: RSS file not found...'); | |
21 | } | |
22 | ||
23 | ?> | |
24 |