Функция eregi() устарела. Как я могу заменить eregi(). Я пытаюсь использовать preg_match, но затем перестаю работать.
я нам это помочь:
http://takien.com/513/how-to-fix-function-eregi-is-deprecated-in-php-5-3-0.php
КОД ДО:
if ( ! eregi("convert$", $this->library_path))
{
if ( ! eregi("/$", $this->library_path)) $this->library_path .= "/";
$this->library_path .= 'convert';
}
if (eregi("gd2$", $protocol))
{
$protocol = 'image_process_gd';
}
КОД ТОГДА:
if ( ! preg_match("convert$/i", $this->library_path))
{
if ( ! preg_match("/$/i", $this->library_path)) $this->library_path .= "/";
$this->library_path .= 'convert';
}
if (preg_match("gd2$/i", $protocol))
{
$protocol = 'image_process_gd';
}