title: .py file showing code in browser instead of running
body: <p>I'm trying to get started with Python but can't get my server setup up correctly for localhost(using Ampps). Python is running just fine through IDLE and command line, however, when I open up the file in the browser the code is displayed and not run.</p>
  
  <p>I followed this <a href="http://www.imladris.com/Scripts/PythonForWindows.html">http://www.imladris.com/Scripts/PythonForWindows.html</a> tutorial for getting cgi set up, but it's not working.</p>
  
  <p>Here's the code for my "hello world" program, if that makes any difference.</p>
  
  <pre><code>#!/usr/bin/env python
  # -*#!/usr/bin/python
  
  print "Content-type:text/html\r\n\r\n"
  print '&lt;html&gt;'
  print '&lt;head&gt;'
  print '&lt;title&gt;Hello Word - First CGI Program&lt;/title&gt;'
  print '&lt;/head&gt;'
  print '&lt;body&gt;'
  print '&lt;h2&gt;Hello Word! This is my first CGI program&lt;/h2&gt;'
  print '&lt;/body&gt;'
  print '&lt;/html&gt;'
  </code></pre>
  
  <p>Any suggestions?</p>