/    Sign up×
Community /Pin to ProfileBookmark

How to off Notices in windows vista

Hi,

I have new version of wamp and it keeps on showing on Notices how can i get rid of them. Please help i guess they can be put off from php.ini file but how can anyone help me on this thanks.

to post a comment
PHP

8 Comments(s)

Copy linkTweet thisAlerts:
@NogDogNov 16.2009 — See the [B]error_reporting[/B] setting in your php.ini file.
Copy linkTweet thisAlerts:
@tariq_wajihaauthorNov 17.2009 — I have checked that but it doesn't worked out ?
Copy linkTweet thisAlerts:
@NogDogNov 17.2009 — What did you change it to?

Did you restart the web server after you changed it?

PS: Have you considered fixing your code so that it doesn't generate those errors/notices?
Copy linkTweet thisAlerts:
@tariq_wajihaauthorNov 17.2009 — i asked one of my friend he told me to remove ; infront of the error_reporting

and yes i remove the errors but still it keep on showing me notices
Copy linkTweet thisAlerts:
@NogDogNov 17.2009 — But what is the exact value assigned to error_reporting. For example is it something like:
<i>
</i>error_reporting [color=red]E_ALL[/color]

If so, to not report notices you'd need:
<i>
</i>error_reporting E_ALL &amp; ~E_NOTICE

And of course you could set display_errors to off so that no error messages get displayed and instead only get logged to the error log.
Copy linkTweet thisAlerts:
@tariq_wajihaauthorNov 18.2009 — This is mentioned there
[CODE]error_reporting = E_ALL & ~E_NOTICE & ~E_WARNING[/CODE]
Copy linkTweet thisAlerts:
@NogDogNov 18.2009 — And I'll still reiterate: the best solution is to fix your code so that no notices or warnings are generated. While the code may "work", any such notices indicate that it is not optimal.

When you get to the production environment, I recommend turning display_errors off, as it can be a security hole to have any system-generated error message displayed to the user, which may give them an insight as to what your script is doing.

Lastly, for any line of code that you expect to possibly throw an error message and you are willing to live with it as is, you can use the "@" operator to suppress errors for the rest of that line, though most of the time that's probably just lazy programming. (Of course, most programmers are lazy. ? )
Copy linkTweet thisAlerts:
@tariq_wajihaauthorNov 19.2009 — Yes thanks i have been working on that and quite successful thanks once again ?
×

Success!

Help @tariq_wajiha 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.22,
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,
)...