All,
The following error is generated by the following sequence of code:
Error: Fatal error: Call to a member function on a non-object in /var/www/html/internal/wiki/includes/Title.php on line 1196
Begin Code: (Note: $_SERVER["REMOTE_USER"] = jcstraff) (in modified User.php) $name = $_SERVER["REMOTE_USER"]; $u = User::newFromName( $name ); (elsewhere in User.php) function newFromName( $name ) { $u = new User(); $t = Title::newFromText( $name ); ... (in Title.php) /* static */ function &newFromText( $text, $defaultNamespace = 0 ) { $fname = 'Title::newFromText'; ... /** * Normally, all wiki links are forced to have * an initial capital letter so [[foo]] and [[Foo]] * point to the same place. * * Don't force it for interwikis, since the other * site might be case-sensitive. */ if( $wgCapitalLinks && $this->mInterwiki == '') { $t = $wgContLang->ucfirst( $r ); # # # # # # <== LINE 1196 } else { $t = $r; } :End Code
There are lots of "$r"s throughout Title.php, but they all seem to be used temporarily and are set explicitly before each use... I cannot see where the "$r" on line 1196 originates. When I comment out this Title.php block, the code works fine (with other issues that will be discussed in a later email.) Did I find a bug or am I doing something wrong/unnatural/evil/etc.?
- John