perl-embperl mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jean-Christophe Boggio <>
Subject Re: Encoding problem
Date Mon, 26 Apr 2010 10:15:55 GMT

Since I seem to be the only one having problems with utf8 forms, I guess
the problem is me not expecting the correct things to happen.

The following is a simple html test page with a simple form. I expect the
result to be utf-8 but it's not (until I comment out the Encode::_utf8_on() line).

Is this normal ? Do you have the same behaviour ? Can someone explain (or point me
to a doc explaining) the confusion I'm making ?

Thanks for your help,

<!doctype html>
	use utf8;
	use Encode;
# Encode::_utf8_on($fdat{$_}) for keys %fdat;

$http_headers_out{'Content-Type'}="text/html; charset=utf-8";

	[+ utf8::is_utf8($fdat{nom}) ? 'utf8' : 'other' +]
	<br />
	Received : [+ $fdat{nom} +]<br />
	<form method="post" accept-charset="UTF-8">
		<input type="text" id="nom" name="nom" />
		<input type="submit" value="go" />


PS: In the same directory I have a base.epl file containing
[- Execute('*'); -]

Jean-Christophe Boggio                       -o)                       /\\
Independant Consultant and Developer        _\_V

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message