-
as seen on Super User
- Search for 'Super User'
iconv -l outputs too few encodings on CentOS 6.5:
$ iconv -l
10646-1:1993, 10646-1:1993/UCS4, ANSI_X3.4-1968, ANSI_X3.4-1986, ANSI_X3.4, ASCII, CP367, CSASCII, CSUCS4, IBM367,
ISO-10646, ISO-10646/UCS2, ISO-10646/UCS4, ISO-10646/UTF-8,
ISO-10646/UTF8, ISO-IR-6, ISO-IR-193, …
>>> More
-
as seen on Stack Overflow
- Search for 'Stack Overflow'
I'm running Ruby 1.8.7 with Rails 2.3.5 on Ubuntu 10.04 64-bit. I've written a method that should take a string like this, "École À la Découverte" and output a file-system name like this "ecole_a_la_decouverte":
(Iconv.new('US-ASCII//TRANSLIT', 'utf-8').iconv "École À la Découverte").gsub(/[^\w\s-\—]/…
>>> More
-
as seen on Stack Overflow
- Search for 'Stack Overflow'
Hi all,
I am on Mac Os X 10.5 (but I reproduced the issue on 10.4)
I am trying to use iconv to convert an UTF-8 file to ASCII
the utf-8 file contains characters like 'éàç'
I want the accented characters to be turned into their closest ascii equivalent
so
my command is this :
iconv -f UTF-8…
>>> More
-
as seen on Stack Overflow
- Search for 'Stack Overflow'
I have a problem with iconv tool. I try to call it from rake file in that way:
Dir.glob("*.txt") do |file|
system("iconv -f UTF-8 -t 'ASCII//TRANSLIT' #{ file } >> ascii_#{ file }")
end
But one file is converted partly (size of partialy converted: 10059092 bytes, before convertion: 10081854)…
>>> More
-
as seen on Stack Overflow
- Search for 'Stack Overflow'
I'm attempting to remove accents from characters in PHP string as the first step to making the string usable in a URL.
I'm using the following code:
$input = "Fóø Bår";
setlocale(LC_ALL, "en_US.utf8");
$output = iconv("utf-8", "ascii//TRANSLIT", $input);
print($output);
The output I would expect…
>>> More