#1
  1. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2004
    Posts
    167
    Rep Power
    11

    .py in IIS trouble


    i have to get python running on IIS

    tried this helpful page: http://support.microsoft.com/default...en-us%3B276494

    but when i try the localhost/scripts/test.py, i get a "save as" dialog box.

    suggestions?
  2. #2
  3. No Profile Picture
    Contributing User
    Devshed Novice (500 - 999 posts)

    Join Date
    Nov 2004
    Location
    There where the rabbits jump
    Posts
    556
    Rep Power
    12
    could you maybe show us the code of test.py

    Comments on this post

    • eriksays agrees : always show your code
    Those people who think they know everything are a great annoyance to those of us who do.
  4. #3
  5. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2004
    Posts
    167
    Rep Power
    11
    here's the python code, but it shouldn't necessarily matter, IIS still doesn't know what to do with the file itself.

    print
    print 'Status: 200 OK'
    print 'Content-type: text/html'
    print

    print '<HTML><HEAD><TITLE>Python Sample CGI</TITLE></HEAD>'
    print '<BODY>'
    print '<H1>This is a header</H1>'

    print '<p>' #this is a comment
    print 'See this is just like most other HTML'
    print '<br>'
    print '</BODY>'
  6. #4
  7. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2004
    Posts
    167
    Rep Power
    11
    now i feel silly. it WAS in the code. the 'Status: 200 Ok' was breaking it.

    thanks

IMN logo majestic logo threadwatch logo seochat tools logo