Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7655143
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T12:26:16+00:00 2026-05-31T12:26:16+00:00

Depending on which error reporting I set, my web app either works or displays

  • 0

Depending on which error reporting I set, my web app either works or displays a ton of errors. I was under the impression I didn’t need to initiate variables in PHP but setting the second error reporting seems to require it. What is going here? Should I go through and initiate all my variables?

error_reporting(E_ALL ^ E_NOTICE);

error_reporting(E_ALL | E_STRICT);
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-31T12:26:17+00:00Added an answer on May 31, 2026 at 12:26 pm

    You are asking about whether to suppress the warning for uninitialized variables, but the code you are posting suppresses ALL E_NOTICE warnings. This is not quite the same thing, but it’s as close as you can get directly to what you’re asking; there is no way to suppress only uninitialized variable notices.

    In a way, notices are possibly the most important warning/error messages of all because they point out potential logic errors, which are among the most difficult to identify and fix.

    Given your options:

    1. Suppress ALL E_NOTICE warnings.
    2. Fix all uninitialized variables in your code.

    I would recommend going with #2. It’s more work upfront, but a well-timed E_NOTICE might just save you a whole mess of trouble one day.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have an SSIS package, which depending on a boolean variable, should either go
I have a web form that has 2 radio buttons, depending on which one
I'm trying to create an automated error reporting tool for our Java desktop app.
Since I need to do some checks depending on which control is on focus
I want to override OnMouseClick and OnMouseDoubleClick and perform different actions depending on which
I have a group of three radio buttons. Depending on which radio button is
I have an application which had optional extras depending on if the user has
I have a combobox from which i need to programmatically disable items depending on
I have a simple function in which an array is declared with size depending
I have a php script (generator.php) which generates certain HTML/XML/SVG depending on various conditions.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.