Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re^5: How to avoid decoding string to utf-8.

by Corion (Patriarch)
on Oct 12, 2020 at 09:19 UTC ( [id://11122738]=note: print w/replies, xml ) Need Help??


in reply to Re^4: How to avoid decoding string to utf-8.
in thread How to avoid decoding string to utf-8.

If the data comes from a web application, consider that at least for form submissions, the browser sends you the character encoding in a header. If the web application sends the data by Javascript, talk to the web developers that they need to makes sure that their data is always UTF-8.

  • Comment on Re^5: How to avoid decoding string to utf-8.

Replies are listed 'Best First'.
Re^6: How to avoid decoding string to utf-8.
by Anonymous Monk on Oct 12, 2020 at 09:32 UTC
    Hi Corion,

    Charset seem to set up to utf-8,

    META HTTP-EQUIV="Content-type" CONTENT="text/html; charset=utf-8
    Thank you.

      That is the charset of the web page, not the charset that the browser sends you when it submits form data.

      Usually, setting the charset of the web page should ensure UTF-8, but it seems that this depends on the browser. I still recommend looking at the headers of the incoming request.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11122738]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others meditating upon the Monastery: (4)
As of 2024-04-25 22:48 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found