Function eregi() is deprecated error using php 5.3

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
hrkama
Forum Newbie
Posts: 1
Joined: Wed Dec 09, 2009 3:07 am

Function eregi() is deprecated error using php 5.3

Post by hrkama »

Hello!

I have installed kolab2 mailserver on openSUSE 11.2. + Horde web mail client (works on php5.3).

It seems that everything works, but there is one small problem:

Every time I sent an e-mail I get an error in the /var/log/kolab/filter.log file

Dec 08 15:38:03 Kolab Filter (pid=12846) [error] [horde] PHP Error: Function eregi() is deprecated; Code: 0 [on line 146 of "/usr/share/php5/PEAR/Horde/Kolab/Filter/Response.php"]

Can anyone help me with this error? I also attached Response.php

Many thanks!
Hrkama.
Attachments
Response.7z
Response.php
(2.11 KiB) Downloaded 1 time
User avatar
requinix
Spammer :|
Posts: 6617
Joined: Wed Oct 15, 2008 2:35 am
Location: WA, USA

Re: Function eregi() is deprecated error using php 5.3

Post by requinix »

You should start using the PCRE functions, such as preg_match, instead of the ereg functions because they will be removed in future versions of PHP.

1) It's more convenient for us if you post the code inline and not attached.
2) Only post the relevant sections.
Post Reply