Jump to content
xisto Community
BCD

Running Python Code On Server. Help Needed.

Recommended Posts

Hello,I am learning Python. I tested some basic codes like hello world code on PC with Python 2.6 installed. I was thinking if the hosting supports Python. I have the Logic Plan ($1.95+SSH access). Is python supported on this plan?I am a bit confused. There seem to be many Python interpreters available like cgi, fast cgi, wxpython and mod_python. I don't how to execute code for other interpreters. I searched for some info on running Python code on server. One of them told to copy the .py files to cgi-bin folder. I tried executing a simple hello world script with .py extension, no luck gave 500 internal server error. I checked MIME types, py was not defined there. It had only cgi, so I renamed it to .cgi but still it shows "500 INternal Server Error". I also gave it 755 permission with no luck. What am I doing wrong?I tried what I could, but then I need to ask the first question again "Is Python supported in Logic Package"? Thanks in advance.

Share this post


Link to post
Share on other sites

Python is supported, but because the server is not using mod_python, running a Python script is different than what you would normally expect. If the Python script is not constructed properly, then you'll get that 500 internal server error. I do not have the knowledge on running Python with CGI, but you may want to look into Python with CGI.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.