I am getting the following error when attempting to buy something in the shop at www.1dt.biz/shop.
I wondered if you could point me in the right direction on how I could fix it?
Deprecated: Function eregi() is deprecated in /home/1dt/web/shop/includes/functions/general.php on line 1090
Deprecated: Function eregi() is deprecated in /home/1dt/web/shop/includes/functions/general.php on line 1090
Deprecated: Function eregi() is deprecated in /home/1dt/web/shop/includes/functions/general.php on line 1090
Deprecated: Function eregi() is deprecated in /home/1dt/web/shop/includes/functions/general.php on line 1090
Deprecated: Function eregi() is deprecated in /home/1dt/web/shop/includes/functions/general.php on line 1090
Warning: Cannot modify header information - headers already sent by (output started at /home/1dt/web/shop/includes/functions/general.php:1090) in /home/1dt/web/shop/includes/functions/general.php开发者_JS百科 on line 33
Assuming the site is yours, you should stop using eregi
as it's deprecated.
You are using eregi
, and that is deprecated (as the warning says)
The last warning is because the warnings allready send a header you can't send another one
best option: replace eregi with a preg variant: http://php.net/manual/en/function.preg-match.php
second best option: set error_reporting
to something that doesn't show the deprecated errors. (error_reporting(E_ALL ^ E_DEPRECATED);
or something like that.)
Use preg_match http://www.php.net/manual/en/function.preg-match.php
you can use @eregi()
to suppress warnings from that call.
or use preg_match
instead, because eregi
is deprecated
eregi() was deprecated in PHP 5.3 you either need to replace that call with preg_match() or change your warnings to ignore deprecated functions (not recommended).
You should use preg_match
, because eregi
is deprecated and will be removed
The following warning is caused by a header change attempt after it is too late (i.e. you have already echo'd, etc):
Warning: Cannot modify header information - headers already sent by (output started at /home/1dt/web/shop/includes/functions/general.php:1090) in /home/1dt/web/shop/includes/functions/general.php on line 33
The depreciation warning is obvious and answered a bunch already here.
精彩评论