Question: I have a `.csv` file. I grab the file using `jQuery.get()`. 

```
$.get("data.csv", function(data) {
    console.log(data)
}, "text")

```

Later I want to save the file in an xml.

Now my problem is the datatype of my text.

What I have Å, ë, ö, etc.

What I output �, �, �, �

**How can I get the correct format of the text from a .csv file into javascript?**

Edit
----

My meta charset is OK: `<meta charset="utf-8">`

But notice that I don't display the output of the csv file, I just add some more info and save it in an xml. 

When I console.log the output I see these � chars. The same when I save it in the xml. But in my csv file I have the correct char.

Edit 2
------

I just found [this awesome tool](http://www.adrianparr.com/?p=142). It is in AS3.

When I insert `Å ë ö` I need the output of `escape()`.

When I use javascript.escape() for `Å` I get weird chars like `%uFFFD` instead of `%C5` so I guess my script tries to escape `�` to `%uFFFD`

Solution
--------

Here the solution for people who have the same problem.

```
$.ajaxSetup({
    'beforeSend' : function(xhr) {
        xhr.overrideMimeType('text/html; charset=iso-8859-1');
    }
})

$.get("data.csv", function(data) {
    console.log(data)
}, "text")

```

Answer: 
you need to replace special characters with ISO Latin codes.
for more reference check this link: <http://www.utexas.edu/learn/html/spchar.html>
Use one of the escape sequences in the string. For instance,The escape sequences in Javascript all begin with the backslash character, . This character lets the application processing the string know that what follows is a sequence of characters that need special handling.