diff --git a/FancyCaptcha.php b/FancyCaptcha.php index 21931a85a..63273a901 100644 --- a/FancyCaptcha.php +++ b/FancyCaptcha.php @@ -216,8 +216,9 @@ class FancyCaptcha extends SimpleCaptcha { $file = $this->imagePath( $salt, $hash ); if( file_exists( $file ) ) { - header( 'Content-type: image/png' ); - readfile( $file ); + global $IP; + require_once "$IP/includes/StreamFile.php"; + wfStreamFile( $file ); return true; } }