Closed Thread
Results 1 to 2 of 2

Thread: Php - CGI Error

  1. #1
    thesquirrel16 is offline Newbie
    Join Date
    Apr 2007
    Posts
    12
    Rep Power
    0

    Php - CGI Error

    Sidewinder | Please use [php], [code] and [quote] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted.

    Hi, ok so I have seen a lot of forums with this error and can't seem to find one that has a solution to it. Anyhow I came up with a simple example of a site that would trigger this error.

    There error itself is: The specified CGI application misbehaved by not returning a complete set of HTTP headers. The headers it did return are:

    The site where you can find this is error
    (if this goes straight to the error open the page in IE)
    here is the code I used.

    Code:
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
    <title>error</title>
    <script type="text/JavaScript">
    <!--
    function MM_jumpMenu(targ,selObj,restore){ //v3.0
      eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
      if (restore) selObj.selectedIndex=0;
    }
    //-->
    </script>
    </head>

    <body>
    This is a simple example of the
    <h1>CGI Error</h1>
    <p>The specified CGI application misbehaved by not returning a complete set of HTTP headers.  The headers it did return are:</p>
    <p>&nbsp;</p><?php
        $thecat
    =$_GET['cat'];
        if(
    $thecat == ""){$thecat 'Select Category';}

    ?>
    <form name="form1" id="form1">
      <select name="menu1" onchange="MM_jumpMenu('parent',this,0)">
        <option value="/error.php?cat=One">One</option>
        <option value="/error.php?cat=Two">Two</option>
        <option selected="selected"><?php echo $thecat ?></option>
      </select>
    </form>
    <p>&nbsp;</p>
    </body>
    </html>


    I believe this has something to do with getting the value from the URL. Anyone know how to fix this problem?

    Sidewinder | Please use [php], [code] and [quote] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted.
    Last edited by John; 05-19-2007 at 02:57 PM.

  2. CODECALL Circuit advertisement
    Join Date
    Always
    Posts
    Many

     
  3. #2
    Join Date
    Jul 2006
    Location
    Amherst, New York, United States
    Posts
    6,277
    Blog Entries
    26
    Rep Power
    20
    I'm not really sure how this replicates the error. It always displays the error message because it is statically coded into the html. Unless I'm missing something?

    I just did a quick google on the error message and it seems like a bug. Have a look here, this may be of help.
    http://bugs.php.net/bug.php?id=25863

Closed Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [help]Parse error: syntax error, unexpected $end
    By kiddies in forum PHP Development
    Replies: 3
    Last Post: 07-18-2010, 02:58 PM
  2. Replies: 5
    Last Post: 06-20-2010, 10:52 PM
  3. Replies: 1
    Last Post: 06-18-2010, 05:26 AM
  4. My error-free code has an error. (Switches/Cases)
    By Sundosia in forum C and C++
    Replies: 3
    Last Post: 08-07-2008, 12:16 PM
  5. Replies: 1
    Last Post: 05-06-2008, 05:16 AM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts