Questions tagged [mojibake]

Garbled text that is the result of bytes being decoded using an incorrect coding.

Mojibake is the phenomenon which occurs when text is decoded from a byte stream using the wrong character encoding, resulting in a sequence of characters which is unreadable. The term "mojibake" is derived from Japanese where it literally means "unintelligible sequence of characters".

Example mojibake:

اÙ"إعÙ"ان اÙ"عاÙ"Ù

References:

150 questions
0
votes
2 answers

python unicode get value / get text

Let's say I have an unicode variable: uni_var = u'Na teatr w pi\xc4\x85tek' I want to have a string, which will be the same as uni_var, just without the "u", so: str_var = 'Na teatr w pi\xc4\x85tek' How can I do it? I would like to find something…
pbialy
  • 1,025
  • 14
  • 26
0
votes
3 answers

mysql - funny square characters added to the value when inserting it into table

I have a php script that inserts values into mySQL table INSERT INTO stories (title) VALUES('$_REQUEST[title]); I checked the values of my request variables before going into the table and it's fine. But when I add title=john to the table for…
stone
  • 841
  • 3
  • 16
  • 26
0
votes
0 answers

DotNetZip - Extracting files that contain non-ascii characters

I'm trying to extract a zip archive that contains files which contain Japanese characters. When I view the contents of them after extracting, the Japanese characters appear as gibberish. This also happens with Winrar/Winzip which is why I was…
Sakuya
  • 660
  • 5
  • 23
0
votes
2 answers

Python Codecs package not able to decode byte

I am using Python 2.7.3 and BeuatofulSoup to grab data from a website's table, then using codecs to write content to a file. One of the variables I collect, occasionally has garbled characters in it. For example, if the website table looks like…
Mark Clements
  • 465
  • 7
  • 25
0
votes
1 answer

JSF2.0: Mojibake for primefaces4.0

Mojibake problem [I use netbeans - jsf 2.2 - primefaces 4.0 - Mysql database] I use Arabic in my JSF application and unfortunately the Arabic values sent to the server as other characters like this (بÙÙØ³ ÙØ¨ ) (seen by debugger) and so stored in…
0
votes
1 answer

Munged Characters - Pound Signs From XML

I am trying to extract £ signs from an XML feed (full version is here > http://mjsiphone.com/scotjobsnet/) A mini version is here > http://scotjobsnet.co.uk.ni.strategiesuk.net/testfeed.xml I have no control over the source of the feed or the source…
MonkeyMagix
  • 677
  • 2
  • 10
  • 30
0
votes
1 answer

Identify encoding and convert characters

Every once in a while, a customer from China will place an order on my site, and sometimes their name and address information will be written to the MySQL database in a series of characters that I can't identify or translate. For example, the…
0
votes
1 answer

Writing unicode type objects to file in Python

I'm trying to write unicode strings to a file in Python but when I read the file using linux "cat" or "less" the correct characters are not written, instead they show up as garbage. I am reading the object from an Oracle database. When I print the…
user45183
  • 529
  • 1
  • 7
  • 16
0
votes
1 answer

set file encoding attributes of *.txt file on webserver

gh-pages is mobibaking a text file . . . Our CI build server copies some build artifacts to gh-pages. Locally, I can see that the file-encoding is UTF-8, and if I download the file, and open it, it renders just fine in a text-editor. However, in…
Jasper Blues
  • 28,258
  • 22
  • 102
  • 185
0
votes
1 answer

Mojibake in reply email (but not every time) when a form is submitted

I hope this is not too specific a question... any thoughts are appreciated. When someone fills out my contact form (UTF-8 encoded), the data correctly enters a MySQL database (UTF-8 encoded throughout) and a reply email is sent to the person who…
Coleen
  • 23
  • 9
0
votes
2 answers

Mojibake characters showing after exporting excel

I am not sure if anyone has encountered this problem. Here are the steps made to replicate the issue. Steps: 1. Go to the List --> Contact Persons page. 2. Click on the "Export" button to generate .XLS report for the Contact Persons List. 3. Close…
AndieC
  • 1
0
votes
1 answer

POST request from android to PHP

I want to send a POST request from android to a PHP application in utf-8 with the below code: List params = new ArrayList(); params.add(new BasicNameValuePair(Site.SQL_QUERY, "just a test 東京")); UrlEncodedFormEntity…
johann
  • 1,115
  • 8
  • 34
  • 60
-1
votes
1 answer

Running simple script meant to fix Mojibake with Python and ftfy gives "*** Remote Interpreter Reinitialized ***"

When I run it nothing happens except "*** Remote Interpreter Reinitialized ***". # https://junschoi.github.io/posts/ftfy_guide/ import ftfy def main(): # Added by pyscripter. pass ftfy.fix_text('This text should be in “quotesâ€\x9d.') #…
-1
votes
2 answers

Encoding Issue with data from MySQL database

I have a sql database that has encoding issues, so it's returning me a result that is similar to this: "Cuvée" From what I can tell this is because it was encoded to latin-1 when it should have been encoded to UTF-8 (please correct me if I'm…
brunoban
  • 177
  • 3
  • 12
-1
votes
1 answer

Site code to enable UTF-8 to EBCDIC encoding

I'm trying to transmit a rather large UTF-8 file to a Z/OS dataset. Unfortunately, the command SITE EN=MBCS MBD=(1047,1208) RECFM=VB TYPE A STOR STORE.WRK.DATA responds with 504 Multi-byte encoding not supported for RECFM=FB It seems the…
Stavr00
  • 3,219
  • 1
  • 16
  • 28
1 2 3
9
10