diff --git a/_test/tests/inc/parser/lexer.test.php b/_test/tests/inc/parser/lexer.test.php
index d0965a13e6c055539bcceb76a2722dd47cc664da..c506659286da542d96bc0eafaa26d7042d84512c 100644
--- a/_test/tests/inc/parser/lexer.test.php
+++ b/_test/tests/inc/parser/lexer.test.php
@@ -146,7 +146,7 @@ class TestOfLexerStateStack extends DokuWikiTest {
 }
 
 class TestParser {
-    function TestParser() {
+    function __construct() {
     }
     function accept() {
     }
@@ -364,7 +364,7 @@ class TestOfLexerHandlers extends DokuWikiTest {
 
 class TestParserByteIndex {
 
-    function TestParserByteIndex() {}
+    function __construct() {}
 
     function ignore() {}
 
diff --git a/inc/IXR_Library.php b/inc/IXR_Library.php
index 8392986806e171b1122b9b4016ea5133465b671f..301a8d9e1db6c24d09cb79b5ea5b90eb30e2d56f 100644
--- a/inc/IXR_Library.php
+++ b/inc/IXR_Library.php
@@ -52,7 +52,7 @@ class IXR_Value {
      * @param mixed $data
      * @param bool $type
      */
-    function IXR_Value($data, $type = false) {
+    function __construct($data, $type = false) {
         $this->data = $data;
         if(!$type) {
             $type = $this->calculateType();
@@ -201,7 +201,7 @@ class IXR_Message {
     /**
      * @param string $message
      */
-    function IXR_Message($message) {
+    function __construct($message) {
         $this->message =& $message;
     }
 
@@ -388,7 +388,7 @@ class IXR_Server {
      * @param bool $data
      * @param bool $wait
      */
-    function IXR_Server($callbacks = false, $data = false, $wait = false) {
+    function __construct($callbacks = false, $data = false, $wait = false) {
         $this->setCapabilities();
         if($callbacks) {
             $this->callbacks = $callbacks;
@@ -621,7 +621,7 @@ class IXR_Request {
      * @param string $method
      * @param array $args
      */
-    function IXR_Request($method, $args) {
+    function __construct($method, $args) {
         $this->method = $method;
         $this->args = $args;
         $this->xml = <<<EOD
@@ -684,7 +684,7 @@ class IXR_Client extends DokuHTTPClient {
      * @param int $port
      * @param int $timeout
      */
-    function IXR_Client($server, $path = false, $port = 80, $timeout = 15) {
+    function __construct($server, $path = false, $port = 80, $timeout = 15) {
         parent::__construct();
         if(!$path) {
             // Assume we have been given a URL instead
@@ -779,7 +779,7 @@ class IXR_Error {
      * @param int $code
      * @param string $message
      */
-    function IXR_Error($code, $message) {
+    function __construct($code, $message) {
         $this->code = $code;
         $this->message = htmlspecialchars($message);
     }
@@ -829,7 +829,7 @@ class IXR_Date {
     /**
      * @param int|string $time
      */
-    function IXR_Date($time) {
+    function __construct($time) {
         // $time can be a PHP timestamp or an ISO one
         if(is_numeric($time)) {
             $this->parseTimestamp($time);
@@ -899,7 +899,7 @@ class IXR_Base64 {
     /**
      * @param string $data
      */
-    function IXR_Base64($data) {
+    function __construct($data) {
         $this->data = $data;
     }
 
@@ -923,7 +923,7 @@ class IXR_IntrospectionServer extends IXR_Server {
     /** @var string[] */
     var $help;
 
-    function IXR_IntrospectionServer() {
+    function __construct() {
         $this->setCallbacks();
         $this->setCapabilities();
         $this->capabilities['introspection'] = array(
@@ -1106,7 +1106,7 @@ class IXR_ClientMulticall extends IXR_Client {
      * @param string|bool $path
      * @param int $port
      */
-    function IXR_ClientMulticall($server, $path = false, $port = 80) {
+    function __construct($server, $path = false, $port = 80) {
         parent::IXR_Client($server, $path, $port);
         //$this->useragent = 'The Incutio XML-RPC PHP Library (multicall client)';
     }
diff --git a/inc/events.php b/inc/events.php
index 256fb561e7e81810a28c83fa700bdcb0a392051f..35d55d0e3fda5f98b17eba1174e215925abc0a3d 100644
--- a/inc/events.php
+++ b/inc/events.php
@@ -31,7 +31,7 @@ class Doku_Event {
      * @param string $name
      * @param mixed $data
      */
-    function Doku_Event($name, &$data) {
+    function __construct($name, &$data) {
 
         $this->name = $name;
         $this->data =& $data;
@@ -153,7 +153,7 @@ class Doku_Event_Handler {
      * constructor, loads all action plugins and calls their register() method giving them
      * an opportunity to register any hooks they require
      */
-    function Doku_Event_Handler() {
+    function __construct() {
 
         // load action plugins
         /** @var DokuWiki_Action_Plugin $plugin */
diff --git a/inc/form.php b/inc/form.php
index 00eea9b3a084e12c7a36ed2527b18df043237aec..748983281e94d35989caba4bad52b99460ab768e 100644
--- a/inc/form.php
+++ b/inc/form.php
@@ -55,7 +55,7 @@ class Doku_Form {
      *
      * @author  Tom N Harris <tnharris@whoopdedo.org>
      */
-    function Doku_Form($params, $action=false, $method=false, $enctype=false) {
+    function __construct($params, $action=false, $method=false, $enctype=false) {
         if(!is_array($params)) {
             $this->params = array('id' => $params);
             if ($action !== false) $this->params['action'] = $action;
diff --git a/inc/parser/handler.php b/inc/parser/handler.php
index b8e2de82ae48f372e4d6faf1b878b00d444bc2ba..815ac39c5d343dd57c16a992b504c5f21cd72182 100644
--- a/inc/parser/handler.php
+++ b/inc/parser/handler.php
@@ -17,7 +17,7 @@ class Doku_Handler {
 
     var $rewriteBlocks = true;
 
-    function Doku_Handler() {
+    function __construct() {
         $this->CallWriter = new Doku_Handler_CallWriter($this);
     }
 
@@ -295,7 +295,7 @@ class Doku_Handler {
         switch ( $state ) {
             case DOKU_LEXER_ENTER:
                 $ReWriter = new Doku_Handler_Preformatted($this->CallWriter);
-                $this->CallWriter = & $ReWriter;
+                $this->CallWriter = $ReWriter;
                 $this->_addCall('preformatted_start',array(), $pos);
             break;
             case DOKU_LEXER_EXIT:
@@ -715,15 +715,21 @@ function Doku_Handler_Parse_Media($match) {
 }
 
 //------------------------------------------------------------------------
-class Doku_Handler_CallWriter {
+interface Doku_Handler_CallWriter_Interface {
+    public function writeCall($call);
+    public function writeCalls($calls);
+    public function finalise();
+}
+
+class Doku_Handler_CallWriter implements Doku_Handler_CallWriter_Interface {
 
     var $Handler;
 
     /**
      * @param Doku_Handler $Handler
      */
-    function Doku_Handler_CallWriter(& $Handler) {
-        $this->Handler = & $Handler;
+    function __construct(Doku_Handler $Handler) {
+        $this->Handler = $Handler;
     }
 
     function writeCall($call) {
@@ -748,7 +754,7 @@ class Doku_Handler_CallWriter {
  *
  * @author    Chris Smith <chris@jalakai.co.uk>
  */
-class Doku_Handler_Nest {
+class Doku_Handler_Nest implements Doku_Handler_CallWriter_Interface {
 
     var $CallWriter;
     var $calls = array();
@@ -762,8 +768,8 @@ class Doku_Handler_Nest {
      * @param  string     $close          closing instruction name, this is required to properly terminate the
      *                                    syntax mode if the document ends without a closing pattern
      */
-    function Doku_Handler_Nest(& $CallWriter, $close="nest_close") {
-        $this->CallWriter = & $CallWriter;
+    function __construct(Doku_Handler_CallWriter_Interface $CallWriter, $close="nest_close") {
+        $this->CallWriter = $CallWriter;
 
         $this->closingInstruction = $close;
     }
@@ -808,7 +814,7 @@ class Doku_Handler_Nest {
     }
 }
 
-class Doku_Handler_List {
+class Doku_Handler_List implements Doku_Handler_CallWriter_Interface {
 
     var $CallWriter;
 
@@ -818,8 +824,8 @@ class Doku_Handler_List {
 
     const NODE = 1;
 
-    function Doku_Handler_List(& $CallWriter) {
-        $this->CallWriter = & $CallWriter;
+    function __construct(Doku_Handler_CallWriter_Interface $CallWriter) {
+        $this->CallWriter = $CallWriter;
     }
 
     function writeCall($call) {
@@ -1018,7 +1024,7 @@ class Doku_Handler_List {
 }
 
 //------------------------------------------------------------------------
-class Doku_Handler_Preformatted {
+class Doku_Handler_Preformatted implements Doku_Handler_CallWriter_Interface {
 
     var $CallWriter;
 
@@ -1028,8 +1034,8 @@ class Doku_Handler_Preformatted {
 
 
 
-    function Doku_Handler_Preformatted(& $CallWriter) {
-        $this->CallWriter = & $CallWriter;
+    function __construct(Doku_Handler_CallWriter_Interface $CallWriter) {
+        $this->CallWriter = $CallWriter;
     }
 
     function writeCall($call) {
@@ -1078,7 +1084,7 @@ class Doku_Handler_Preformatted {
 }
 
 //------------------------------------------------------------------------
-class Doku_Handler_Quote {
+class Doku_Handler_Quote implements Doku_Handler_CallWriter_Interface {
 
     var $CallWriter;
 
@@ -1086,8 +1092,8 @@ class Doku_Handler_Quote {
 
     var $quoteCalls = array();
 
-    function Doku_Handler_Quote(& $CallWriter) {
-        $this->CallWriter = & $CallWriter;
+    function __construct(Doku_Handler_CallWriter_Interface $CallWriter) {
+        $this->CallWriter = $CallWriter;
     }
 
     function writeCall($call) {
@@ -1170,7 +1176,7 @@ class Doku_Handler_Quote {
 }
 
 //------------------------------------------------------------------------
-class Doku_Handler_Table {
+class Doku_Handler_Table implements Doku_Handler_CallWriter_Interface {
 
     var $CallWriter;
 
@@ -1185,8 +1191,8 @@ class Doku_Handler_Table {
     var $currentRow = array('tableheader' => 0, 'tablecell' => 0);
     var $countTableHeadRows = 0;
 
-    function Doku_Handler_Table(& $CallWriter) {
-        $this->CallWriter = & $CallWriter;
+    function __construct(Doku_Handler_CallWriter_Interface $CallWriter) {
+        $this->CallWriter = $CallWriter;
     }
 
     function writeCall($call) {
@@ -1551,7 +1557,7 @@ class Doku_Handler_Block {
      *
      * @author Andreas Gohr <andi@splitbrain.org>
      */
-    function Doku_Handler_Block(){
+    function __construct(){
         global $DOKU_PLUGINS;
         //check if syntax plugins were loaded
         if(empty($DOKU_PLUGINS['syntax'])) return;
diff --git a/inc/parser/lexer.php b/inc/parser/lexer.php
index b46a5f505c38207dfefd6c2295482cba64773d49..5afcc520ad0d226b113b5ccc555c8d709adc51bc 100644
--- a/inc/parser/lexer.php
+++ b/inc/parser/lexer.php
@@ -46,7 +46,7 @@ class Doku_LexerParallelRegex {
      *                         for insensitive.
      * @access public
      */
-    function Doku_LexerParallelRegex($case) {
+    function __construct($case) {
         $this->_case = $case;
         $this->_patterns = array();
         $this->_labels = array();
@@ -232,7 +232,7 @@ class Doku_LexerStateStack {
      * @param string $start        Starting state name.
      * @access public
      */
-    function Doku_LexerStateStack($start) {
+    function __construct($start) {
         $this->_stack = array($start);
     }
 
@@ -296,7 +296,7 @@ class Doku_Lexer {
      * @param boolean $case            True for case sensitive.
      * @access public
      */
-    function Doku_Lexer(&$parser, $start = "accept", $case = false) {
+    function __construct(&$parser, $start = "accept", $case = false) {
         $this->_case = $case;
         /** @var Doku_LexerParallelRegex[] _regexes */
         $this->_regexes = array();
diff --git a/inc/parser/parser.php b/inc/parser/parser.php
index 5f86cf5c4ebf8be1505d1520936fae62cd0c5066..65510071e9dedec8e30aa323fd0f484476a95aef 100644
--- a/inc/parser/parser.php
+++ b/inc/parser/parser.php
@@ -226,7 +226,7 @@ class Doku_Parser_Mode_Plugin extends DokuWiki_Plugin implements Doku_Parser_Mod
 //-------------------------------------------------------------------
 class Doku_Parser_Mode_base extends Doku_Parser_Mode {
 
-    function Doku_Parser_Mode_base() {
+    function __construct() {
         global $PARSER_MODES;
 
         $this->allowedModes = array_merge (
@@ -248,7 +248,7 @@ class Doku_Parser_Mode_base extends Doku_Parser_Mode {
 //-------------------------------------------------------------------
 class Doku_Parser_Mode_footnote extends Doku_Parser_Mode {
 
-    function Doku_Parser_Mode_footnote() {
+    function __construct() {
         global $PARSER_MODES;
 
         $this->allowedModes = array_merge (
@@ -416,7 +416,7 @@ class Doku_Parser_Mode_formatting extends Doku_Parser_Mode {
     /**
      * @param string $type
      */
-    function Doku_Parser_Mode_formatting($type) {
+    function __construct($type) {
         global $PARSER_MODES;
 
         if ( !array_key_exists($type, $this->formatting) ) {
@@ -470,7 +470,7 @@ class Doku_Parser_Mode_formatting extends Doku_Parser_Mode {
 //-------------------------------------------------------------------
 class Doku_Parser_Mode_listblock extends Doku_Parser_Mode {
 
-    function Doku_Parser_Mode_listblock() {
+    function __construct() {
         global $PARSER_MODES;
 
         $this->allowedModes = array_merge (
@@ -504,7 +504,7 @@ class Doku_Parser_Mode_listblock extends Doku_Parser_Mode {
 //-------------------------------------------------------------------
 class Doku_Parser_Mode_table extends Doku_Parser_Mode {
 
-    function Doku_Parser_Mode_table() {
+    function __construct() {
         global $PARSER_MODES;
 
         $this->allowedModes = array_merge (
@@ -648,7 +648,7 @@ class Doku_Parser_Mode_file extends Doku_Parser_Mode {
 //-------------------------------------------------------------------
 class Doku_Parser_Mode_quote extends Doku_Parser_Mode {
 
-    function Doku_Parser_Mode_quote() {
+    function __construct() {
         global $PARSER_MODES;
 
         $this->allowedModes = array_merge (
@@ -682,7 +682,7 @@ class Doku_Parser_Mode_acronym extends Doku_Parser_Mode {
     var $acronyms = array();
     var $pattern = '';
 
-    function Doku_Parser_Mode_acronym($acronyms) {
+    function __construct($acronyms) {
         usort($acronyms,array($this,'_compare'));
         $this->acronyms = $acronyms;
     }
@@ -729,7 +729,7 @@ class Doku_Parser_Mode_smiley extends Doku_Parser_Mode {
     var $smileys = array();
     var $pattern = '';
 
-    function Doku_Parser_Mode_smiley($smileys) {
+    function __construct($smileys) {
         $this->smileys = $smileys;
     }
 
@@ -762,7 +762,7 @@ class Doku_Parser_Mode_wordblock extends Doku_Parser_Mode {
     var $badwords = array();
     var $pattern = '';
 
-    function Doku_Parser_Mode_wordblock($badwords) {
+    function __construct($badwords) {
         $this->badwords = $badwords;
     }
 
@@ -797,7 +797,7 @@ class Doku_Parser_Mode_entity extends Doku_Parser_Mode {
     var $entities = array();
     var $pattern = '';
 
-    function Doku_Parser_Mode_entity($entities) {
+    function __construct($entities) {
         $this->entities = $entities;
     }
 
diff --git a/lib/plugins/config/settings/config.class.php b/lib/plugins/config/settings/config.class.php
index 316cc2c593e5db1519547e5214828e96ef8ae3c9..f2d43bff6067da3ee395f575ca11a65130251e14 100644
--- a/lib/plugins/config/settings/config.class.php
+++ b/lib/plugins/config/settings/config.class.php
@@ -37,7 +37,7 @@ if (!class_exists('configuration')) {
          *
          * @param string $datafile path to config metadata file
          */
-        public function configuration($datafile) {
+        public function __construct($datafile) {
             global $conf, $config_cascade;
 
             if (!file_exists($datafile)) {
@@ -434,7 +434,7 @@ if (!class_exists('setting')) {
          * @param string $key
          * @param array|null $params array with metadata of setting
          */
-        public function setting($key, $params=null) {
+        public function __construct($key, $params=null) {
             $this->_key = $key;
 
             if (is_array($params)) {
diff --git a/lib/plugins/config/settings/extra.class.php b/lib/plugins/config/settings/extra.class.php
index fd3a90e284e5d6f8afb2935b0d11ba99f36c088c..c6a3f9dae52536dfdf02bcdc0b8e399b279ad822 100644
--- a/lib/plugins/config/settings/extra.class.php
+++ b/lib/plugins/config/settings/extra.class.php
@@ -20,7 +20,7 @@ if (!class_exists('setting_sepchar')) {
             for ($i=0;$i<strlen($str);$i++) $this->_choices[] = $str{$i};
 
             // call foundation class constructor
-            $this->setting($key,$param);
+            parent::__construct($key,$param);
         }
     }
 }
diff --git a/lib/plugins/popularity/action.php b/lib/plugins/popularity/action.php
index 9e2e78d11b55c84ee9992ea1adc8ee186a20c160..d5ec0f5c5d183efce736c9e8bcdbbd0206ebca23 100644
--- a/lib/plugins/popularity/action.php
+++ b/lib/plugins/popularity/action.php
@@ -15,7 +15,7 @@ class action_plugin_popularity extends Dokuwiki_Action_Plugin {
      */
     var $helper;
 
-    function action_plugin_popularity(){
+    function __construct(){
         $this->helper = $this->loadHelper('popularity', false);
     }
 
diff --git a/lib/plugins/popularity/admin.php b/lib/plugins/popularity/admin.php
index ab569b8b4bf7ad164ee05aabec710709060a1603..a2c3c6c8bc35616e275a091740d145d1ef6416a7 100644
--- a/lib/plugins/popularity/admin.php
+++ b/lib/plugins/popularity/admin.php
@@ -20,7 +20,7 @@ class admin_plugin_popularity extends DokuWiki_Admin_Plugin {
     var $helper;
     var $sentStatus = null;
 
-    function admin_plugin_popularity(){
+    function __construct(){
         $this->helper = $this->loadHelper('popularity', false);
     }
 
diff --git a/lib/plugins/popularity/helper.php b/lib/plugins/popularity/helper.php
index 8673fb5aff830d5a3b21766660595c75665d0e60..e99f6a60cb30b74d8ccf02f5897f7343b69998ae 100644
--- a/lib/plugins/popularity/helper.php
+++ b/lib/plugins/popularity/helper.php
@@ -30,7 +30,7 @@ class helper_plugin_popularity extends Dokuwiki_Plugin {
     var $popularityLastSubmitFile;
 
 
-    function helper_plugin_popularity(){
+    function __construct(){
         global $conf;
         $this->autosubmitFile = $conf['cachedir'].'/autosubmit.txt';
         $this->autosubmitErrorFile = $conf['cachedir'].'/autosubmitError.txt';
diff --git a/lib/plugins/usermanager/admin.php b/lib/plugins/usermanager/admin.php
index 9cb9b0c4033f9e0de17360707567f5b2e7ec7c79..0d92e5cc19f781eff52c41bdc85768c9389c54ec 100644
--- a/lib/plugins/usermanager/admin.php
+++ b/lib/plugins/usermanager/admin.php
@@ -36,7 +36,7 @@ class admin_plugin_usermanager extends DokuWiki_Admin_Plugin {
     /**
      * Constructor
      */
-    public function admin_plugin_usermanager(){
+    public function __construct(){
         /** @var DokuWiki_Auth_Plugin $auth */
         global $auth;