【发布时间】:2013-09-29 18:20:26
【问题描述】:
你能告诉我两者的区别吗? php中的$variable和@$variable
<?php
curl function abc
{
get information of url and return information string
}
$html=abc();
$doc=DOMDocument();
@$doc->LoadHTML($html);
?>
如果我们采用普通变量,它会给出错误,为什么会这样 有什么区别
【问题讨论】:
-
@防止php报错。
-
真的不要用那个东西。现在您知道它的作用了,请将其从您的代码中删除并改用
libxml_use_internal_errors()。
标签: php curl domdocument