IIS connecting to Python through CGI

You must have Python already installed in your system.
Turns  windows features on off

Open Internet Information Services (IIS) Manager
In left panel go to defalut web site
Default IIS
At center panel check for Handler Mappings
Handler Mappings

At right panel check for Add Script Map
Add Script Map

Search for python.exe in your PC
Add Script Map
Enter the details as per the above picture. You can browse your PC and select the python.exe in your system.

Go to root of your localhost and create test.py file with this code
print("HTTP/1.0 200 OK\n")
print('Hello World')
Output
Hello World
You can import library
print("HTTP/1.0 200 OK\n")

import math 
print(math.pi)


plus2net.com



Post your comments , suggestion , error , requirements etc here




We use cookies to improve your browsing experience. . Learn more
HTML MySQL PHP JavaScript ASP Photoshop Articles FORUM . Contact us
©2000-2019 plus2net.com All rights reserved worldwide Privacy Policy Disclaimer