开发者

PHP error message [closed]

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center. Closed 11 years ago.

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.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜