Form submission of Russian characters

From: Gunnar Hjalmarsson (noreply_at_gunnar.cc)
Date: 12/15/03


Date: Mon, 15 Dec 2003 22:24:27 +0100


[ Move of the thread
http://groups.google.com/groups?threadm=b5884818.0312150701.427b8073%40posting.google.com
at clpmisc ]

Alan J. Flavell wrote:
> On Mon, 15 Dec 2003, Gunnar Hjalmarsson wrote:
>> To continue this experiment, I suggest that you replace the
>> second line in the script with:
>>
>> print "Content-Type: text/html; charset=Windows-1251\n\n<html><body>";
>
> That should help, yes: my investigations showed that browsers
> typically performed their form submission using the same character
> coding as the HTML page which contained the form, _provided_ the
> submitted characters could be represented in that character coding.
>
> However (ObPerl-ish), I refer you to the comment at
> http://www.perldoc.com/perl5.8.0/lib/Encode/Supported.html -
>
> "it is beyond the power of words to describe the way HTML browsers
> encode non-ASCII form data. To get a general impression, visit
> http://ppewww.ph.gla.ac.uk/~flavell/charset/form-i18n.html

I reviewed the latter document. Thanks, Alan! Before I had read it, I
thought I had found a working approach for dealing with i18n in CGI
scripts. Now I know that I didn't have a clue. ;-)

>> If the actual form is on a static HTML page, you rather need a
>> meta header at that page:
>>
>> <meta http-equiv="Content-Type" content="text/html;
>> charset=Windows-1251">
>
> Objection, your Honour! You preferably need web server
> configuration (e.g AddCharset) to cause the web server to send out
> a proper HTTP header.
>
> W3C Hints and Tips:
> http://www.w3.org/International/O-HTTP-charset.html
>
> meta http-equiv="Content-type" is a second-rate ersatz for HTML
> (and an incomplete and problematical ersatz for XHTML).

Well, your objection was not unexpected. But, to be honest, how 'bad'
is it to use meta tags? After all, unlike the methods described in
that W3C document, the meta tag method is 'portable'.

-- 
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
-- 
PLEASE NOTE: comp.infosystems.www.authoring.cgi is a
SELF-MODERATED newsgroup. aa.net and boutell.com are
NOT the originators of the articles and are NOT responsible
for their content.
HOW TO POST to comp.infosystems.www.authoring.cgi:
http://www.thinkspot.net/ciwac/howtopost.html


Relevant Pages

  • Re: GL Head Writing (Ok, just my ideas.)
    ... LOTS of questions about the time after Reva went off the bridge. ... Josh pined for her. ... I just find the character boring now. ... Ron Raines may be a nice guy, but this Alan is skeevy. ...
    (rec.arts.tv.soaps.cbs)
  • Re: GL-Revas health, for starters
    ... Dinah and Alan are in cahoots to take get Spaulding away from Bill, ... Olivia and Buzz had a very sweet scene, ... enough to make me wonder if he might get together with Cassie, Grady ... discussion with another character that revealed these things. ...
    (rec.arts.tv.soaps.cbs)
  • GL -- Phillips Biological & Breakdown
    ... Alan keeping Phillip hidden away to the point where Phillip eventually ... What has Sam been doing with herself? ... I would like to see Reva 'meet' the survivor in something ... Reva is a fictious character. ...
    (rec.arts.tv.soaps.cbs)
  • Re: GL-creepy scene today
    ... Alan has never been sane, or a good guy, but ventured into a whole new ... Another scene like that, and there ... is bringing the character of Alan back for me, ... I was uncomfortable watching it, and when I saw it in yesterday's previews. ...
    (rec.arts.tv.soaps.cbs)