responseContent retorna caracteres ilegiveis

O Método Get não reconhece os caracteres da Língua Portuguesa (~, ^, ´etc).

O valor de responseContent ao invés de mostrar as letra acentuadas, mostra o carate "?".

Como resolver isso?

Obrigado

[translated]
The Get Method does not recognize Portuguese language characters (~, ^, 'etc).
The responseContent value, instead of showing the accented letters, shows the character "?".
How to solve this?

Thanks

Try using the uriDecode block (in the web component blocks) on your responseContent. Does that help ?

Obrigado pela dica, mas não deu certo.

Veja como ficou...

You used the uriEncode block :upside_down_face:

Try with the uriDecode block :+1:

Usar UriEncode gerou outros caracteres e usar UriDecode não alterou em nada o texto original que continua com "?" nos caracteres da Língua Portuguesa...

Continuamos na mesma...

OK, this sounds like the data you are fetching with the web component is not UTF-8 encoded. You need to ensure that it is.

https://community.appinventor.mit.edu/search?q=UTF-8

1 Like

A origem dos dados são de uma tabela MYSQL da Internet que vem através de uma rotina PHP.

Os testes para ler os dados mostram todos os caracteres latinos, mas o responseContent não.

Veja a coleta dos dados via PHP. Aparecem todos os caracteres latinos...

E esta é a chamada no AppInventor

It could be that your mySQL is not set to utf-8.

See here:

https://www.a2hosting.co.uk/kb/developer-corner/mysql/convert-mysql-database-utf-8

Creio que já está configurado para UTF-8

see also Q3 here https://puravidaapps.com/mysql.php#q

Taifun


Trying to push the limits! Snippets, Tutorials and Extensions from Pura Vida Apps by icon24 Taifun.

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.