Carl A. Posted December 5, 2011 Share Posted December 5, 2011 I wanted to start using Helio using Python/Django. However, whatever I do I'll get a 500 error. So, I tried to make to simple cgi scripts with python, one using us-ascii and another in utf8. The former works, the latter gives me again a 500 error. Am I missing something? There is a high probability that I will use UTF-8 later in the project so I don't want to use ascii.(.. also: I don't know where the error log is located :-() agon. Quote Link to comment Share on other sites More sharing options...
Guest xaav Posted December 5, 2011 Share Posted December 5, 2011 Please post the content of your scripts. Quote Link to comment Share on other sites More sharing options...
Carl A. Posted December 7, 2011 Author Share Posted December 7, 2011 ANSI (actually saved as us-ascii), which prints the hello-world message:#!/usr/bin/python print "Content-Type: text/plain\n\n" print "Hello World: ANSI"and UTF-8 (which gives a 500 Error):#!/usr/bin/python print "Content-Type: text/plain\n\n" print "Hello World: UTF-8".. nothing too fancy. I rechecked just to be sure:The permission on for both files, which are in the same directory, is 755. Quote Link to comment Share on other sites More sharing options...
Guest xaav Posted December 7, 2011 Share Posted December 7, 2011 Are you using the windows character to end your lines? 1 Quote Link to comment Share on other sites More sharing options...
Carl A. Posted December 9, 2011 Author Share Posted December 9, 2011 Thank you so far. The django app is developed on Ubuntu, so I assume there it's unixy.The two scripts were actually windowsy, but they are both. I changed the utf8 one to Unix-line-endings, but the problem remains. ... after I changed the encoding of the UTF8-file to ansi, it works. ---------------- Later this evening ------Ha, got it:I had to remove the BOM from the UTF8 file. Now, if this is also the problem with my django application (currently merely a hello-world) then it would be rather annoying to have the BOM removed from every file that is created from python/django. Well, I will look into this during the weekend. Quote Link to comment Share on other sites More sharing options...
Carl A. Posted December 12, 2011 Author Share Posted December 12, 2011 I'm not sure if the django problem with the same error is related. I'm going to make a new thread for it.this thread can be marked solved. Quote Link to comment Share on other sites More sharing options...
Guest xaav Posted December 12, 2011 Share Posted December 12, 2011 Glad your question got answered! Please spare a few minutes to take our brief survey: http://feedback.heliohost.org/ Your participation in this survey is greatly appreciated. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.