Mantis - Quercus
|
|||||
Viewing Issue Advanced Details | |||||
|
|||||
ID: | Category: | Severity: | Reproducibility: | Date Submitted: | Last Update: |
1619 | minor | always | 02-20-07 10:46 | 02-28-07 10:38 | |
|
|||||
Reporter: | ferg | Platform: | |||
Assigned To: | nam | OS: | |||
Priority: | normal | OS Version: | |||
Status: | closed | Product Version: | |||
Product Build: | Resolution: | fixed | |||
Projection: | none | ||||
ETA: | none | Fixed in Version: | 3.1.1 | ||
|
|||||
Summary: | 0001619: mediawiki null object | ||||
Description: |
(rep by Alex Sharaz) Mediawiki 1.9.2 When you try to perform a search on a media wiki page you get the following error message /usr/web/commswiki/webapps/wiki/includes/SpecialSearch.php:324: Fatal Error: null: 'getText' is an unknown method. From SpecialSearch.php function showHit( $result, $terms ) { $fname = 'SpecialSearch::showHit'; wfProfileIn( $fname ); global $wgUser, $wgContLang, $wgLang; $t = $result->getTitle(); if( is_null( $t ) ) { wfProfileOut( $fname ); return "<!-- Broken link in search result -->\n"; } $sk =& $wgUser->getSkin(); $contextlines = $wgUser->getOption( 'contextlines', 5 ); $contextchars = $wgUser->getOption( 'contextchars', 50 ); $link = $sk->makeKnownLinkObj( $t ); $revision = Revision::newFromTitle( $t ); <!—Line 324 à $text = $revision->getText(); <!-- à $size = wfMsgExt( 'nbytes', array( 'parsemag', 'escape'), $wgLang->formatNum( strlen( $text ) ) ); $lines = explode( "\n", $text ); $max = intval( $contextchars ) + 1; $pat1 = "/(.*)($terms)(.{0,$max})/i"; $lineno = 0; $extract = ''; wfProfileIn( "$fname-extract" ); foreach ( $lines as $line ) { if ( 0 == $contextlines ) { break; } ++$lineno; $m = array(); if ( ! preg_match( $pat1, $line, $m ) ) { continue; } --$contextlines; $pre = $wgContLang->truncate( $m[1], -$contextchars, '...' ); |
||||
Steps To Reproduce: | |||||
Additional Information: | |||||
Relationships | |||||
Attached Files: |
Notes | |||||
|
|||||
|
|