How to decode strange HTML entities like ’ in wordpress?

I'm developing WordPress Android app which loads post from my Wordpress site using JSON API. In JSON data its found some special characters &#8230, &#8217, &#8230. when android webview loads post it stops loading at this special characters. It doesn't loads the data after this characters. How to decode or skip/delete these characters in wordpress site or android app.

In one of the post contain &#8217 after this character post is not visible. It has decoded only & but failed to decode #8217

I'm newbie in wordpress.

JSON link for POST

app post screenshot

1 Answer

You can decode the output with the function html_entity_decode

$input = "Hello friends I’m sharing my experience...." echo html_entity_decode($input); 

outputs to: Hello friends I’m sharing my experience....

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

You Might Also Like