Page MenuHomePhabricator

eregi deprecated in PHP 5.3 - SpecialUpload.php line 1501
Closed, InvalidPublic

Description

Author: duane

Description:
eregi causing error on PHP 5.3:

[Tue Jan 26 16:30:25 2010] [error] [client *.*.*.*] PHP Deprecated: Function eregi() is deprecated in /Library/WebServer/Sites/XXXXXX/wiki.xxxxxxxxx.com/phase3/includes/specials/SpecialUpload.php on line 1501, referer: http://wiki.xxxxxxxxx.com/index.php/Special:Upload

change from
if (eregi("<!DOCTYPE *X?HTML",$chunk)) return true;

to
if (preg_match("/<!DOCTYPE *X?HTML/i",$chunk)) return true;

to fix


Version: 1.15.x
Severity: normal

Details

Reference
bz22278

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 21 2014, 10:56 PM
bzimport set Reference to bz22278.
bzimport added a subscriber: Unknown Object (MLST).

This is already fixed in trunk. Not sure if it's worth backporting a fix to the REL1_15 branch.

I don't think so.
MediaWiki 1.16 should be out soon* and E_DEPRECATED isn't supposed to be enabled in production anyway.

I don't think MediaWiki actually supports PHP 5.3 anyway.

Or is that PHP 6?