Skip to content

Tag: parsing

Replace (fix) non UTF-8 character in string

When I am parsing a string to become a JSON object there are some special characters that are replaced with the black question mark (�), I believe that is an issue with the encoding of the character. Is there any way of replacing the question mark with the correct character (é) or is it lost? Answer From the …

JSON.parse incorrect string format

i have this string: and i want it to become like this: I tried with stringify and replace and i ended up with And from here i wanted to replace the single quotation marks ‘ with double quotation marks ” but when i did, in beginning and ending of the string appeared an extra ” Any tips on how…

How to parse html div text to json

I try to parse data from html to json structure, but I get empty strings. I do it first time. Here example of repeatable div block: But I get this: How I can get json text from classes .itemVuzTitle and .tooltipq to json structure with fields name like title and scores? Please, help with this question. It hel…