Overview

Packages

  • None
  • Wicked

Classes

  • Text_Wiki_Parse_Attribute
  • Text_Wiki_Parse_Code2
  • Text_Wiki_Parse_Freelink2
  • Text_Wiki_Parse_Image2
  • Text_Wiki_Parse_Registrylink
  • Text_Wiki_Parse_Wickedblock
  • Text_Wiki_Parse_Wikilink2
  • Wicked_Application
  • Wicked_Block_Page
  • Overview
  • Package
  • Class
  • Tree
 1: <?php
 2: /**
 3:  * A block to display a Wiki page.
 4:  *
 5:  * Copyright 2004-2012 Horde LLC (http://www.horde.org/)
 6:  *
 7:  * See the enclosed file COPYING for license information (GPL). If you
 8:  * did not receive this file, see http://www.horde.org/licenses/gpl.
 9:  *
10:  * @author Jason Felice <jason.m.felice@gmail.com>
11:  */
12: class Wicked_Block_Page extends Horde_Core_Block
13: {
14:     /**
15:      */
16:     public function __construct($app, $params = array())
17:     {
18:         parent::__construct($app, $params);
19: 
20:         $this->_name = _("Wiki page");
21:     }
22: 
23:     /**
24:      */
25:     protected function _title()
26:     {
27:         $page = Wicked_Page::getPage($this->_params['page']);
28:         return htmlspecialchars($page->pageName());
29:     }
30: 
31:     /**
32:      */
33:     protected function _content()
34:     {
35:         $page = Wicked_Page::getPage($this->_params['page']);
36:         return $page->render(Wicked::MODE_BLOCK);
37:     }
38: 
39:     /**
40:      */
41:     protected function _params()
42:     {
43:         return array(
44:             'page' => array(
45:                 'type' => 'text',
46:                 'name' => _("Name of wiki page to display"),
47:                 'default' => 'Wiki/Home'
48:             )
49:         );
50:     }
51: 
52: }
53: 
API documentation generated by ApiGen