WordPress.org

Ready to get started?Download WordPress

Forums

Twitter for WordPress
Escaping HTML entities (1 post)

  1. Pneumonic
    Member
    Posted 3 years ago #

    Not sure if anyone else has had this issue, but I had a post where I used an ampersand - but obviously didn't use & because it's twitter and it would look idiotic - so when I would check validation, it wouldn't validate. To fix it I did put this on line 71 (which is directly after this line): $msg = " ".substr(strstr($message['description'],': '), 2, strlen($message['description']))." ";

    $msg = htmlentities($msg);

    If you are using UTF8 encoding, you can try doing this instead:

    $msg = html_entity_decode($msg);
    $msg = htmlentities($msg);

    Hope that helps someone.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic