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 475425
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T00:23:13+00:00 2026-05-13T00:23:13+00:00

This question has been asked before in a more general way. I want to

  • 0

This question has been asked before in a more general way. I want to display error messages on a particular page on my production server, and I do not have access to the php.ini file. What is the best way to enable all errors and warnings on a particular PHP page on your production server?

I have tried ERROR_REPORTING(E_ALL);.

  • 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-13T00:23:14+00:00Added an answer on May 13, 2026 at 12:23 am

    To enable errors, you must use error_reporting before the point where those are triggered (for example, at the beginning of your PHP script) :

    error_reporting(E_ALL);
    

    And to have the error displayed, you should configure display_errors :

    ini_set('display_errors', 'On');
    

    (This one should be disabled on a production server, which means you might have to enable it this way, even after having configured error_reporting)

    Of course, all this can be encapsulated in an if block, to make sure only you can see the error messages — especially if you are doing this on a live production website ; for instance :

    if ($_SESSION['is_admin'])
    {
        error_reporting(E_ALL);
        ini_set('display_errors', 'On');
    }
    

    And to get things a bit prettier, you might also want to configure html_errors :

    ini_set('html_errors', 'On');
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

This has been asked before (question no. 308581) , but that particular question and
This question has been asked more than once before, but I have not found
This question has been asked before ( link ) but I have slightly different
I know this question has been asked before, but I ran into a problem.
I know this specific question has been asked before , but I am not
I know this question has been asked a bit before. But looking around I
It's quite possible a question like this has been asked before, but I can't
I know this question has been asked before and I read all the answers
Yes, this question has been asked before, but I don't feel there's been a
Ok, first off, I applogize if this question has been asked before, I've spent

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.