Line | |
---|
1 | <?php
|
---|
2 | require_once(dirname(__FILE__) . '/syndicatedlink.class.php');
|
---|
3 |
|
---|
4 | class MagpieMockLink extends SyndicatedLink {
|
---|
5 | var $url;
|
---|
6 |
|
---|
7 | function MagpieMockLink ($rss, $url) {
|
---|
8 | $this->link = $rss;
|
---|
9 | $this->magpie = $rss;
|
---|
10 | $this->url = $url;
|
---|
11 | $this->id = -1;
|
---|
12 | $this->settings = array(
|
---|
13 | 'unfamiliar category' => 'default',
|
---|
14 |
|
---|
15 | );
|
---|
16 | } /* function MagpieMockLink::MagpieMockLink () */
|
---|
17 |
|
---|
18 | function poll ($crash_ts = NULL) {
|
---|
19 | // Do nothing but update copy of feed
|
---|
20 | $this->magpie = fetch_rss($this->url);
|
---|
21 | $this->link = $this->magpie;
|
---|
22 | } /* function MagpieMockLink::poll () */
|
---|
23 |
|
---|
24 | function uri () {
|
---|
25 | return $this->url;
|
---|
26 | } /* function MagpieMockLink::uri() */
|
---|
27 |
|
---|
28 | function homepage () {
|
---|
29 | return (is_object($this->magpie) ? $this->magpie->channel['link'] : null);
|
---|
30 | } /* function MagpieMockLink::homepage () */
|
---|
31 | } /* class MagpieMockLink */
|
---|
32 |
|
---|
33 |
|
---|
Note:
See
TracBrowser
for help on using the repository browser.