Hi Kudos,
Thanks a lot for all your help so far. I think the problem was with my .cgi file so far. So, I configured the apache so that it directly excuetes my python script(.py) from the brwoser.
http://localhost/cgi-bin/Main.py?myinput=input
however, the input (argument) is not read by the python script when i supplied the input file as shown in URL above. Probably because it is again cgi specific.
I placed this...
User Profile
Collapse
-
create a web service for python application
hi Kudos,
I sorted out the problem with my apache server on windows. Finally the apache server is running with test cgi script. But my actual python application( now, cgi application) is still not running. Actually in the original application the input file is passed as an argument in the command line (c:/ python application.py input).
Is it the problem when i run cgi script...Leave a comment:
-
HI kudos, thanks a lot again for your help
I tried configuring apache server to be able to work with cgi as well.
And I tried with the built-in server script you have provided.
The server is running but i can see only
" your output as a html-string here..." in the browser.
I tried even this simple cgi script (hi.cgi) to execute
(http://localhost:2606/hi.cgi )
but...Leave a comment:
-
create a web service for python application
Hi kudos and Frinavale,
Thanks a lot for your quick responses!
I did followed the steps as you suggested.
1) I inserted my complete python script in between line numbers 21 and 23 of Frinavale's code in the reply. after that i also inserted the "Content-Type" as Kudos suggested.
2) I renamed the file with .cgi extenstion.
...Leave a comment:
-
create a web service for python application
Hi, I am very new to the python web applications. can some one help.
I have a python application with some functions in it.
1) The application reads an input file ( say, IN.txt).
the IN.txt file contains names of three other files( x.dat, y.txt, z.dat) that are
in the same directory.
2) then the application reads the data in the files x.dat, y.txt, z.dat and performs some calculations....
No activity results to display
Show More
Leave a comment: