__construct() public method

public __construct ( $path, $commit = NULL )
コード例 #1
0
 /**
  * Contstruct as a normal article with no differences
  */
 function __construct($param)
 {
     global $wgHooks;
     // This hook allows us to change the class of article to one of our classes
     $wgHooks['InitializeArticleMaybeRedirect'][] = $this;
     // Allow sub-classes to have an edit method that can add its own fields
     $wgHooks['EditPage::showEditForm:fields'][] = array($this, 'onShowEditFormFields');
     // Allow sub-classes to have a save method that can store its fields into the page_props
     $wgHooks['ArticleSave'][] = $this;
     return parent::__construct($param);
 }
コード例 #2
0
ファイル: WikiFilePage.php プロジェクト: claudinec/galan-wiki
 public function __construct($title)
 {
     parent::__construct($title);
     $this->mDupes = null;
     $this->mRepo = null;
 }