mapstruct警告抑制_使用@抑制PHP错误和警告

mapstruct警告抑制

One part of making sure your website is secure in its hosting environment is to handle errors in a good fashion. If you don't have complete control of your hosting environment, you don't know what you can expect in the way of error handling if you don't do everything you can think of.

确保您的网站在其托管环境中安全的一部分是以一种良好的方式处理错误。 如果您无法完全控制托管环境,那么如果您不尽所能想到的事情,那么您将不知道在错误处理方面可以期待什么。

One method I use in all of my programming is to place an '@' character in front of function calls that have potential for returning warnings or errors.

我在所有编程中都使用的一种方法是在函数调用的前面放置一个'@'字符,该字符有可能返回警告或错误。

@require($_SITE['ROOT'].$_FOLDERS['CONTROL'].'logger.php'); // suppress a file not found error
@mysql_connect($host,$user,$pass); // suppress no connection error

I recommend using the @ once your website is in production. I generally don't use the @ on development servers because I want to be aware of errors during development.

我建议您在网站投入生产后使用@。 我通常不在开发服务器上使用@,因为我想在开发过程中注意错误。

翻译自: https://davidwalsh.name/suppress-php-errors-warnings

mapstruct警告抑制

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值