View Full Version : install error!undefined function: mb_eregi()

03-28-2005, 05:43 AM
Fatal error: Call to undefined function: mb_eregi() in d:\usr\www\html\code\phpdig188\includes\config.php on line 109

what's the problem?

03-28-2005, 12:12 PM
Looks like your version of PHP doesn't support that function. Check this out: http://codewalkers.com/phpdocs/function.mb-eregi.html

It says only versions 4.2.0+ support mb_eregi.

03-28-2005, 04:47 PM
thanks a lot :)

04-21-2005, 06:36 AM
Seems PHP 5 doesn't support mb_eregi() as I found trying to upgrade PHPDig from a copy a few years old - so can I assume this will get fixed sometime soon as can't now upgrade any of our servers, and I guess a lot of other people wil be affected as well?

Probably wasn't a good idea relying on an experimental function in the first place?

"This function is EXPERIMENTAL. The behaviour of this function, the name of this function, and anything else documented about this function may change without notice in a future release of PHP. Use this function at your own risk."



04-21-2005, 07:12 AM
Hmm, I think PHP 5 does support mbstring. Look in the php.ini file and check out the php.ini example at http://www.php.net/manual/en/ref.mbstring.php

Not sure what manual you were reading: The mb_eregi function was experimental, but php.net (http://www.php.net/manual/en/function.mb-eregi.php) now says the following FWIW:


(PHP 4 >= 4.2.0)

mb_eregi -- Regular expression match ignoring case with multibyte support


int mb_eregi ( string pattern, string string [, array regs] )

mb_eregi() executes the regular expression match with multibyte support, and returns 1 if matches are found. This function ignore case. If the optional third parameter was specified, the function returns the byte length of matched part, and the array regs will contain the substring of matched string. The functions returns 1 if it matches with the empty string. If no matches found or error happend, FALSE will be returned.

The internal encoding or the character encoding specified in mb_regex_encoding() will be used as character encoding.

See also: mb_regex_encoding(), mb_ereg().

Other posts have indicated a possible issue with PhpDig 1.8.8 RC1 running on PHP 5, but I'm not yet sure if this is related to php.ini settings or whether some PhpDig code needs reworking.