The Doctype is an SGML-type declaration that tells interested user agents which Document Type Definition to use to validate and to interpret the following markup.

This is important in XML-land so that browsers and other programs don't have to do as much guesswork to interpret a document.

That said, I find it hard to believe that printing a header will break sysread. In fact, if you're already using CGI.pm, why not go the extra step and use the param() function to get at your CGI input? Unless I'm way off the mark, you're attempting to read POSTed data from STDIN with sysread (as one would do without CGI.pm).

Depending on how IIS caches information, CGI.pm may have already read the data in, so you'll block until the user agent sends more, which is, effectively, forever until timeout.


In reply to Re: CGI::header() & What's !DOCTYPE..? by chromatic
in thread CGI::header() & What's !DOCTYPE..? by PiEquals3

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.