Call to member function str() on non-object in syntax.php
Hi there,
I use dokuwiki from ubuntu server 14.04 (version 0.0.20131208-1) repository.
After installation of the bureaucracy-plugin all requests to dokuwiki just render a white page. The apache error.log shows:
[Mon Mar 21 08:20:42.429591 2016] [:error] [pid 30687] [client 192.168.1.14:51800] PHP Fatal error: Call to a member function str() on a non-object in /var/lib/dokuwiki/lib/plugins/bureaucracy/syntax.php on line 525, referer: http://192.168.0.1:8002/
What is $this->values['__user__'] = $INPUT->server->str('REMOTE_USER'); expected to return?
Thanks, Felix
Hmm sounds like a relative old version of dokuwiki. The bureaucracy plugin assumes a recent version of DokuWiki which includes the Input classes that support the global $_SERVER variable. Added in https://github.com/splitbrain/dokuwiki/issues/589 Does the repository not offer a more recent version of DokuWiki? or are these not availabe for the LTS?
Sloppy workaround is replacing $INPUT->server->str('REMOTE_USER') by $_SERVER['REMOTE_USER']
Better would be that via repositories a more recent DokuWiki lands... No idea how that proces is going, but I observe that Debian has already some recent versions.. https://packages.debian.org/search?keywords=dokuwiki https://www.dokuwiki.org/install:debian
thanks @Klap-in . The given version is the latest in ubuntu 14.04 LTS. As far as I understand, the dokuwiki bureaucracy plugin page lists it as compatible ("blinky").
If I change the line to $_SERVER['REMOTE_USER'] rendering a page with a form shows error notifications ("Unbekannter Typ "bureaucracy_fieldfieldset" ... for all kind of types -> translation: "Unknown type ..."). Does this look like another incompatibility issue?
Of course I could install manually, but would prefer to have the "managed" solution where I do not have to obverse another channel for updates.