/    Sign up×
Community /Pin to ProfileBookmark

Error Message: Hide Full File Path

Hi,

Upon an error occurring with my PHP scripts, can do I hide the full path of the cooperate file within the error message?

to post a comment
PHP

3 Comments(s)

Copy linkTweet thisAlerts:
@ZnupiMar 19.2008 — As far as I know, the only way to do it is by suppressing the error.
Copy linkTweet thisAlerts:
@DysanauthorMar 19.2008 — What do you mean by that? Is it possible to turn off error message completely? - How?
Copy linkTweet thisAlerts:
@ZnupiMar 19.2008 — To turn off error messages completely:
[code=php]
error_reporting(0);
[/code]

Or, most functions that can give an error can suppress that error by putting an '@' before the function call:
[code=php]
$var = @some_func($parameter);
[/code]

--> http://www.php.net/manual/en/language.operators.errorcontrol.php
×

Success!

Help @Dysan spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.20,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...