Forums

Artiss Twitter Data
QUotation marks in tweet are appearing as &quot (4 posts)

  1. phpadam
    Member
    Posted 7 months ago #

    This plug-in is exactly what I need. I installed it on a client's site and the very first tweet they made contained quotation marks. When the tweet appeared on their website, all the quote marks were replaced with &quot

    Is there a switch of some kind I can flip to fix this?

    http://wordpress.org/extend/plugins/simple-twitter-data/

  2. phpadam
    Member
    Posted 7 months ago #

    I fixed this by assigning the value of $return_data['status'] to a variable and then running htmlspecialchars_decode

    The full code as displayed in my template file is something like this:

    $return_data = simple_twitter_data('user=mytwittername&data=name,status,image,relative');
    $thenewtweet = $return_data['status'];
    $thenewtweet = htmlspecialchars_decode($thenewtweet);
    echo '<p class="fptweeter"><b><a href="http://twitter.com/#!/mytwittername" target=_blank>MyTwitterName</a></b> Latest Tweet [' . $return_data['relative'] . '] </p><p class="fptweet"> ' . $thenewtweet . '</p.>'

    It seems to work

  3. dartiss
    Member
    Posted 6 months ago #

    Thanks for letting me know - I'll add this fix to the next release.

    David.

  4. dartiss
    Member
    Posted 5 months ago #

    I've now released version 2 which fixes this. However, htmlspecialchars_decode limits the plugin to PHP 5, so I've used my own function to achieve it instead.

    David.

Reply

You must log in to post.

About this Plugin

About this Topic