ID: 12061 Comment by: salmanarshad2000 at yahoo dot com Reported By: peters at connection dot ca Status: Bogus Bug Type: IIS related Operating System: Win 2K PHP Version: 4.0.6 New Comment:
None of the tips and tricks mentioned here worked, though the phpMyAdmin people said that the solution is present somewhere on this page. I see three frames, each containing a "CGI Application Misbehaved ..." error whenever I try to view phpMyAdmin. However, if I refresh individual frames one by one in phpMyAdmin they appear, but this work around is not elegant. I believe that some thing goes wrong when simultaneous requests are thrown at php and it doesnot get a chance to complain. The confing I am using is: PHP: 4.3.3 / win32 executable CGI MySQL: 3.23.32 phpMyAdmin: 2.5.3 Webserver: IIS 5.1 on Win XP Professional, SP1 Hardware: Intel P4, 2GHz The same software combination *was working* when I was using it on Win 2000 Profesional on Intel P2, 266MHz machine. Previous Comments: ------------------------------------------------------------------------ [2003-08-28 03:52:43] Jason dot Petit at Vaillant dot co dot uk OK, I was getting the exact same errors sometimes on both frames sometimes only on the left or right frame. I think I found what is causing it :P In config.inc.php you have the following line: $cfg['PmaAbsoluteUri'] = 'http://localhost/PHPMyAdmin'; Notice there is no "/" at the end but their example does. By removing the "/" my pages started to work.... 2 years late but I only just started using php. ------------------------------------------------------------------------ [2003-07-10 15:13:05] michael dot jensen at dnp-services dot com My 2 cents on the CGI error issue: The CGI error discussed here also happens, if you done everything strictly to the books (aka. install.txt), but have a multi-user setup on Windows 2k, and have your account within the Administrators (and probably any other restricted) group. Then, any new directory you create, inherits rights from your group. For IIS to be able to access your directory properly, you must have set access rights for "Everyone" for the folder where your php (or, for that matter, any other CGI) scripts are located. Allowing the default settings (for "Everyone") to be inherited while denying "Write" access rights (you don't want to have those) works fine for me. Using php -i, or php <myfile.php> from the command line does NOT reveal this problem: it works just fine. The problem only occurs when you want to access the page from any browser. Hope it helps. Michael ------------------------------------------------------------------------ [2003-06-11 15:24:35] jwhatcher at hotmail dot com I am using advance server running iis on several machines with php. I understand that this error means many things. What does it mean when you get it intermit tingly? I go to the page and get the error. Refresh the page and it loads. It doesn't happen every time nor does it occur on the same page. But it happens frequent enough to be a problem. Is there any correlation between the exe version and the error. Reason I ask is because on one server I run the dll I have not had one single 502 in my log file. But with the exe it occurs every day. ------------------------------------------------------------------------ [2003-04-18 03:00:30] reznor at geeksanon dot ca Hello, I'm writing in regards to this error-----> cgi error: The specified CGI application misbehaved by not returning a complete set of HTTP headers. The headers it did return are: I've been to every message forum around the world and back and got nothing. What it did get me looking at lots was the php.ini file. I run a Win 2000 Server with the latest greast PHP 4.3.1 mySQL and IIS. When it hit me like a bull in a china shop, I've got this all up and running on my XP pro system to test my code on, let's look at that php.ini file, so I did. And I saw it..... XP setting: doc_root = IIS setting: doc_root = C:\Inetpub\wwwroot OK so I set my IIS php.ini doc_root to the XP setting doc_root = ...and WaBLAM! It worked! ------------------------------------------------------------------------ [2003-02-26 14:06:32] garlandj at hotmail dot com The "misbehaving" error is generated from working with notepad, then saving the file: myphpfile.php What actually gets saved is this: myphpfile.php.txt Be sure to drop down the menu to All Files *.* to eliminate the default .txt extension from be appended. Alternatively, enable viewing of file-extensions and delete the .txt from the end of the file. I cannot however figure out the "undefined variable" problem with Windows 2000/XP. If you have a form and create a post action, the data should be passed so that: I should be able to use HTML like this: <input type="text" size="5" value="" name="myvar"> And then use PHP in the same, or separate PHP file to reference the variable with $myvar. This does NOT work with Windows. When this variable is referenced in the code, an undefined variable error results. Editing the php.ini file is NOT a solution, but does get rid of the error (of course!) Instead of displaying the error, the data is non-existent/empty/not displayed/inacessible. I found a webpage that used the following to obtain all variables, so the data IS being processed and IS accessible, but not as it should be. This code (found elsewhere) will list all variables and correctly display their contents: <?php print "Posted variables: <br>"; foreach($HTTP_POST_VARS as $key=>$value) print $key . " = " . $value . "<br>"; ?> I suppose one could use this as a work-around. Any ideas? ------------------------------------------------------------------------ The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/12061 -- Edit this bug report at http://bugs.php.net/?id=12061&edit=1