I read all the forum entires on this issue, but I still trying to get it solved. I have a windows based hosted server that is running php 5x. I am trying to change my site's PHP setting via the php.settings file in sites/default folder.

I'm not a PHP guy, so I'm not sure this approach is even correct nor the syntax. I have not been able to turn off screen display of errors which I think is the core issue here.

1. Can I change the PHPsettings in the file I mentioned?

2. If 1 is true what is the exact syntax of the entry? I tried something like this....

ini_set('session.display_errors', 0);

Any help would be good

Comments

meerkat’s picture

I've added ini_set ('display_errors', '0'); to the start of my index.php file (between the comment block and the require_once line).

This supressed the errors I was getting on my Brinkster hosted site (Windows/PHP5).

Kodeart’s picture

Little late, but this error is known for Winblows hosted Drupal.

There is no need to suppress the error messages with ini_set.
(D5.6): ~ Line 683 in bootstrap.inc:

if (isset($_SERVER['argv'])) {
      $uri = $_SERVER['SCRIPT_NAME'] .'?'. $_SERVER['argv'][0];
    }

A this point, $_SERVER['argv'] is an empty array, so $uri gets wrong value.
Quick fix would be:

if (isset($_SERVER['argv']) and !empty($_SERVER['argv'])) {
      $uri = $_SERVER['SCRIPT_NAME'] .'?'. $_SERVER['argv'][0];
    }

Works for me on Windows IIS 5.1, PHP 5.1.x, Drupal 5.6 and applies for your index without query strings (www.example.org). Other "/?q=" links should work as expected.

-- Kodeart Software Development

Bluesmoke’s picture

I had same problem and tried replacing line in code as suggested but still gave the same error message. I tried clearing cache etc etc but still appeared. resolved after I clicked through to a few other pages and returned to home page. I then changed code back to original and error message did not re-appear. Bit weird - but perhaps it was something to do with re-setting server variables ($_SERVER)?
Thanks for help