Changeset 888 for trunk/Modules/News/News.php
- Timestamp:
- Dec 27, 2022, 7:50:23 PM (2 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Modules/News/News.php
r880 r888 3 3 include_once(dirname(__FILE__).'/RSS.php'); 4 4 5 class ModuleNews extends AppModule5 class ModuleNews extends Module 6 6 { 7 7 var $RSSChannels; … … 19 19 } 20 20 21 function DoStart() 21 function DoStart(): void 22 22 { 23 $this->System->RegisterPage( 'news', 'PageNews');24 $this->System->RegisterPage( 'rss', 'PageRSS');23 $this->System->RegisterPage(['news'], 'PageNews'); 24 $this->System->RegisterPage(['rss'], 'PageRSS'); 25 25 $this->RegisterRSS(array('Title' => T('News'), 'Channel' => 'news', 26 26 'Callback' => array('PageNews', 'ShowRSS'), 'Permission' => LICENCE_ANONYMOUS)); 27 $this->System->RegisterPageHeader('New', array($this, 'ShowRSSHeader'));27 Core::Cast($this->System)->RegisterPageHeader('New', array($this, 'ShowRSSHeader')); 28 28 } 29 29 … … 69 69 class PageNews extends Page 70 70 { 71 function Show() 71 function Show(): string 72 72 { 73 73 $this->Title = T('News');
Note:
See TracChangeset
for help on using the changeset viewer.