Unable to execute the script

Tim Chase python.list at tim.thechases.com
Fri Aug 10 15:10:15 EDT 2012


On 08/10/12 13:38, Dave Angel wrote:
> On 08/10/2012 01:14 PM, Smaran Harihar wrote:
>> Hi,
>>
>> I have set executable permissions for my py script (cgi-script) but for
>> some reason rather than executing it, the browser simply downloads the py
>> script.
>>
>> Here is the link<http://128.196.142.94/geo/iplantgeo_cgi.py?get=env&from=latlon&lat=42,45,54&lon=-123,-65,-100>.
>> Before it was working on another server. I migrated it to this new domain
>> and it is having this issue. Where am I going wrong?
>>
>>
> Lots of possibilities, though I can't think of any relating to Python.  
> So I didn't try to read your source file.
> 
> Is the location of this script acceptable to your web host?  Some hosts
> deliberately restrict scripts to be in certain places (like /cgi-bin) in
> order to thwart a certain type of cracker.
> 
> Next question, is the python installation actually at the place where
> your shebang points?

And, if the file is on a *nix-like machine (Linux, BSD, Mac,
Solaris, etc), have the executable bits been set?

-tkc






More information about the Python-list mailing list