r56760 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r56759‎ | r56760 | r56761 >
Date:16:04, 22 September 2009
Author:thomasv
Status:ok (Comments)
Tags:todo 
Comment:
commenting out the part that depends on PdfHandler update
Modified paths:
  • /trunk/extensions/ProofreadPage/ProofreadPage.php (modified) (history)

Diff [purge]

Index: trunk/extensions/ProofreadPage/ProofreadPage.php
@@ -1094,7 +1094,7 @@
10951095 $image = wfFindFile( $imageTitle );
10961096 if ( $image && $image->exists() ) {
10971097 $mime = $image->getMimeType();
1098 - if( $mime == 'image/vnd.djvu' || $mime == 'application/pdf') {
 1098+ if( $mime == 'image/vnd.djvu' /*|| $mime == 'application/pdf'*/ ) {
10991099 $text = $image->handler->getPageText($image, $m[2]);
11001100 if ( $text ) {
11011101 $text = preg_replace( "/(\\\\n)/", "\n", $text );

Comments

#Comment by Brion VIBBER (talk | contribs)   16:15, 22 September 2009

Per notes on IRC -- would be best to move getPageText to the base handler class so we can just always call it, and unsupporting formats can just return false. Then this ext doesn't need to worry about which formats support text extraction.

The hardcode is ok for now, since we don't have it in the base class yet.

Status & tagging log