Support » Plugin: Facebook » Ugly HTML characters in FB post

  • J. K.


    Hi there,

    Love the plugin but there’s one thing I hope can be fixed:
    When I post on my wp blog and its sent to my fb page it doesn’t translate the special characters very well, resulting in something like:

    Title & Title – Title
    <p>Post with visible HTML tags

    Can this be fixed?

Viewing 8 replies - 1 through 8 (of 8 total)
  • Ditto that problem here.

    Looks to be the html associated with the time line entry showing in the post? Possibly I did something wrong in the setup of open graph?

    See it here:

    Any plans for a fix on this?

    Also, secondary issue, the photo from my Etsy sidebar widget is showing up in my facebook post. Not a huge problem for me but it does seem rather random.


    Testing this more and it seems what I am getting on the FB page isn’t the time line entry but a duplicate of the what I put in the content box but with mark-up.

    So my fb page entry looks like this:

    <p> Test 4 post content. </p>

    Test 4 post content.

    Also, I am getting an entry on my personal FB account time line, even though ‘The post to author’s timeline box is not checked’.

    Doesn’t appear I can edit the post to FB either to get rid of the markup junk.

    Can somebody fix this? I can opt out on some of the fancier features but the duplication is a deal breaker 🙁

    Thanks for any fix offered.

    I’m seeing the same thing happen at the top of posts to Facebook.
    for example:

    &Nbsp; As I prepare for

    There is space at the top of the post, hence the &Nbsp that does exist in the code. But it shouldn’t be showing up in Facebook.

    Bump. Happening to me to on

    I do had the same issue, As a quick solution i used the fb_strip_and_format_desc() function to trim the html characters.

    Edit fb-social-publisher.php file goto line 232, use fb_strip_and_format_desc() in both name and caption array values like below

    $args = array('access_token' => $fan_page_info[0][3],
            'from' => $fan_page_info[0][2],
            'link' => apply_filters( 'rel_canonical', get_permalink()),
            'picture' => $post_thumbnail_url,
            'name' => fb_strip_and_format_desc(get_the_title()),
            'caption' => fb_strip_and_format_desc(apply_filters( 'the_excerpt', get_the_excerpt() )),
            'description' => fb_strip_and_format_desc( $post ),
            'message' => $fan_page_message,

    Hope this will help to fix the issue.Thanks

    J. K.


    Hi Akhill,
    Thanks for the code, do you paste it in, or replace lines 232-240 with your code?
    Anyway, I tried both but it didn’t really change anything, my test turned out like this:

    FB 0 Twitter test 2
    <p>Excuses we moeten nog iets testen voor facebook & twitter

    So the only place where a special character seemed to be displayed correctly is the ampersand at the end…

    Hi J.K

    I used the plugin function fb_strip_and_format_desc in name and caption values to clear the html characters, and its working fine for me. You can check my page here :

    Can you paste the changed code here.

    I have this same problem, and tried the same fix but there is one additional problem – characters such as apostrophes an ellipsis are showing up as unicode instead of plain text, so:

    Here’s an example

    Shows as:

    Here’s an example

    This looks really bad, is there a fix for this too?

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘Ugly HTML characters in FB post’ is closed to new replies.