Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #42495 > unrolled thread
| Started by | Νίκος Γκρ33κ <nikos.gr33k@gmail.com> |
|---|---|
| First post | 2013-04-01 13:09 -0700 |
| Last post | 2013-04-01 21:33 +0100 |
| Articles | 5 — 5 participants |
Back to article view | Back to comp.lang.python
Switching from Apche to LiteSpeed Νίκος Γκρ33κ <nikos.gr33k@gmail.com> - 2013-04-01 13:09 -0700
Re: Switching from Apche to LiteSpeed John Gordon <gordon@panix.com> - 2013-04-01 20:29 +0000
Re: Switching from Apche to LiteSpeed nagia.retsina@gmail.com - 2013-04-01 22:10 -0700
Re: Switching from Apche to LiteSpeed Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2013-04-02 06:38 +0000
Re: Switching from Apche to LiteSpeed Mark Lawrence <breamoreboy@yahoo.co.uk> - 2013-04-01 21:33 +0100
| From | Νίκος Γκρ33κ <nikos.gr33k@gmail.com> |
|---|---|
| Date | 2013-04-01 13:09 -0700 |
| Subject | Switching from Apche to LiteSpeed |
| Message-ID | <9a35850a-7fcb-4585-84ae-5e13cef9173a@googlegroups.com> |
Just today i changed from HostGator to EZPZ, which means from Apache Web Server to LiteSpeed. Does anyone know why iam seeing what iam seeing at http://superhost.gr I see weird encoding although inside my python script i have: #!/usr/bin/python # -*- coding=utf-8 -* Also dod you advise me to switch to VPS because none of the above webhosters is willing to support Python3 + MySQLdb ? With VPS i could isntall those packages myself and any other module i wish via 'pip install module' What do you think?
[toc] | [next] | [standalone]
| From | John Gordon <gordon@panix.com> |
|---|---|
| Date | 2013-04-01 20:29 +0000 |
| Message-ID | <kjcqnr$g2n$2@reader1.panix.com> |
| In reply to | #42495 |
In <9a35850a-7fcb-4585-84ae-5e13cef9173a@googlegroups.com> =?ISO-8859-7?B?zd/q7/Igw+rxMzPq?= <nikos.gr33k@gmail.com> writes:
> Just today i changed from HostGator to EZPZ, which means from Apache Web Server to LiteSpeed.
> Does anyone know why iam seeing what iam seeing at http://superhost.gr
> I see weird encoding although inside my python script i have:
> #!/usr/bin/python
> # -*- coding=utf-8 -*
I believe the syntax is to use a colon, not an equal sign. i.e.:
# -*- coding: utf-8 -*-
Your example is also missing the final dash after the asterisk.
--
John Gordon A is for Amy, who fell down the stairs
gordon@panix.com B is for Basil, assaulted by bears
-- Edward Gorey, "The Gashlycrumb Tinies"
[toc] | [prev] | [next] | [standalone]
| From | nagia.retsina@gmail.com |
|---|---|
| Date | 2013-04-01 22:10 -0700 |
| Message-ID | <0902473e-d498-45ce-bc98-ea1df7f04f27@googlegroups.com> |
| In reply to | #42498 |
Τη Δευτέρα, 1 Απριλίου 2013 11:29:47 μ.μ. UTC+3, ο χρήστης John Gordon έγραψε: > In <9a35850a-7fcb-4585-84ae-5e13cef9173a@googlegroups.com> =?ISO-8859-7?B?zd/q7/Igw+rxMzPq?= <nikos.gr33k@gmail.com> writes: > > > > > Just today i changed from HostGator to EZPZ, which means from Apache Web Server to LiteSpeed. > > > > > Does anyone know why iam seeing what iam seeing at http://superhost.gr > > > > > I see weird encoding although inside my python script i have: > > > > > #!/usr/bin/python > > > # -*- coding=utf-8 -* > > > > I believe the syntax is to use a colon, not an equal sign. i.e.: > > > > # -*- coding: utf-8 -*- > > > > Your example is also missing the final dash after the asterisk. > > > > -- > > John Gordon A is for Amy, who fell down the stairs > > gordon@panix.com B is for Basil, assaulted by bears > > -- Edward Gorey, "The Gashlycrumb Tinies" Thank you but even like you said i still see ncoding issues as seen in my webpage
[toc] | [prev] | [next] | [standalone]
| From | Steven D'Aprano <steve+comp.lang.python@pearwood.info> |
|---|---|
| Date | 2013-04-02 06:38 +0000 |
| Message-ID | <515a7cd0$0$29891$c3e8da3$5496439d@news.astraweb.com> |
| In reply to | #42498 |
On Mon, 01 Apr 2013 20:29:47 +0000, John Gordon wrote: > In <9a35850a-7fcb-4585-84ae-5e13cef9173a@googlegroups.com> > =?ISO-8859-7?B?zd/q7/Igw+rxMzPq?= <nikos.gr33k@gmail.com> writes: > >> Just today i changed from HostGator to EZPZ, which means from Apache >> Web Server to LiteSpeed. > >> Does anyone know why iam seeing what iam seeing at http://superhost.gr > >> I see weird encoding although inside my python script i have: > >> #!/usr/bin/python >> # -*- coding=utf-8 -* > > I believe the syntax is to use a colon, not an equal sign. i.e.: > > # -*- coding: utf-8 -*- > > Your example is also missing the final dash after the asterisk. I don't think that will make a difference. Encoding declaration lines are *very* flexible, and will match either a colon or equals sign. So long as it matches this regular expression, it will be understood: coding[=:]\s*([-\w.]+) http://docs.python.org/2/reference/lexical_analysis.html#encoding-declarations However, it is important that the encoding being declared matches the actual encoding being used! For example, if you take a Latin-1 file, and declare that it is UTF-8, it won't magically turn the Latin-1 file into UTF-8. Instead you'll get bytes being decoded wrongly. -- Steven
[toc] | [prev] | [next] | [standalone]
| From | Mark Lawrence <breamoreboy@yahoo.co.uk> |
|---|---|
| Date | 2013-04-01 21:33 +0100 |
| Message-ID | <mailman.16.1364848262.17481.python-list@python.org> |
| In reply to | #42495 |
On 01/04/2013 21:09, Νίκος Γκρ33κ wrote: > Just today i changed from HostGator to EZPZ, which means from Apache Web Server to LiteSpeed. > > Does anyone know why iam seeing what iam seeing at http://superhost.gr > > I see weird encoding although inside my python script i have: > > #!/usr/bin/python > # -*- coding=utf-8 -* > > Also dod you advise me to switch to VPS because none of the above webhosters is willing to support Python3 + MySQLdb ? > > With VPS i could isntall those packages myself and any other module i wish via 'pip install module' > > What do you think? > I think you should get your cheque book out and make a donation to the PSF. -- If you're using GoogleCrap™ please read this http://wiki.python.org/moin/GoogleGroupsPython. Mark Lawrence
[toc] | [prev] | [standalone]
Back to top | Article view | comp.lang.python
csiph-web