Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Featured Replies

I sent the following sentence through Google Translation API (english -> french) and the response substituted certain characters for HTML (I think). I played around with DECODE options to return the code to the actual characters I need, but haven't yet found the solution.

Sent: the woman yelled at the man

Received: la femme a crié à l'homme

Full response:

{
  "data": {
    "translations": [
      {
        "translatedText": "la femme a crié à l'homme"
      }
    ]
  }
}

 

Thanks

 

That's not proper JSON: for one thing, there is no need to escape an apostrophe in JSON; for another, if you really wanted to escape it, you would use the form \u0027, not '.

I find it hard to believe that Google would get this wrong (and that you would be the first one to notice) - so I googled (ha!) for 'google translate api escape apostrophe' and found this as the 1st result:

https://stackoverflow.com/a/63272510/17153010:

 

2 hours ago, Jeffrey Bloch said:

I played around with DECODE options

Not sure what you're referring to.

 

  • Author
1 hour ago, comment said:

That's not proper JSON: for one thing, there is no need to escape an apostrophe in JSON; for another, if you really wanted to escape it, you would use the form \u0027, not '.

I find it hard to believe that Google would get this wrong (and that you would be the first one to notice) - so I googled (ha!) for 'google translate api escape apostrophe' and found this as the 1st result:

https://stackoverflow.com/a/63272510/17153010:

 

Not sure what you're referring to.

 

I'll check out the article. Thanks.

1 hour ago, comment said:

That's not proper JSON: for one thing, there is no need to escape an apostrophe in JSON; for another, if you really wanted to escape it, you would use the form \u0027, not '.

I find it hard to believe that Google would get this wrong (and that you would be the first one to notice) - so I googled (ha!) for 'google translate api escape apostrophe' and found this as the 1st result:

https://stackoverflow.com/a/63272510/17153010:

 

Not sure what you're referring to.

 

format=text did the trick. Thanks!

Edited by Jeffrey Bloch

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.