title: End of script output before headers: hello.pl
body: <p>Update: 07/12/13</p>
  
  <p>The script works through command line.</p>
  
  <p>"------extra line" is to show an extra return key stroke in editor.</p>
  
  <hr>
  
  <p>XAMPP: 1.8.2</p>
  
  <p>Server: Apache 2.4</p>
  
  <h2>Issue:</h2>
  
  <p>I keep receiving the error "End of script output before headers: hello.pl" for a simple hello world perl script. I'm trying to execute the script via a web server "xampp".</p>
  
  <h2>Curious Note:</h2>
  
  <p>I can use another Perl script which will initially work. However when I make a simple change such as a space, return or comment "#", the script will no longer function. However if I remove the change and save it the script will work again. </p>
  
  <h2>Check List</h2>
  
  <p>Confirm correct path to perl
  Output header (see perl code below)
  Extra line at end of script (I heard this could resolve issue)
  Confirmed correct privileges in httpd.config
  Transferred file via ftp in ASCII</p>
  
  <p>Perl Script:</p>
  
  <pre><code>#!"C:\xampp\perl\bin\perl.exe"
  
  print "Content-Type: text/html\n\n";
  
  print "hello world";
  
  ------extra line
  </code></pre>
  
  <h2>httpd.config</h2>
  
  <pre><code>&lt;Directory "C:/xampp/htdocs"&gt;;
   Options Indexes FollowSymLinks Includes ExecCGI
   AllowOverride All
   Require all granted
  &lt;/Directory&gt;;
  </code></pre>
  
  <p></p>