Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #2702

    Hello there it looks like apostrophes are still showing up as weird characters in IE. (Shows up as ')

    I have this code in my twitter.php file. Is there a fix for this that anyone knows of?


    <?php

    function twitter_feed($username, $fallback ,$active=true ){

    $feed = “http://search.twitter.com/search.atom?q=from:” . $username . “&rpp=1″;

    function parse_feed($feed) {

    $stepOne = explode(“<content type=”html”>”, $feed);

    if(isset($stepOne[1])){

    $stepTwo = explode(“</content>”, $stepOne[1]);

    $tweet = $stepTwo[0];

    $tweet = html_entity_decode($stepTwo[0]);

    //$tweet = str_replace(“<“, “<“, $tweet);

    //$tweet = str_replace(“>”, “>”, $tweet);

    //$tweet = str_replace(“””, ‘”‘, $tweet);

    return $tweet;

    }

    }

    if($active){

    $twitterFeed = @file_get_contents($feed);

    $data[1] = parse_feed($twitterFeed);

    }else{

    $twitterFeed = ”;

    $data[1] =”;

    }

    $data[0] =’Follow me in twitter';

    if ($data[1] ==”) $data[1] = $fallback;

    return $data;

    }

    #38999

    Hey,

    can you post a link to a page where these weird characters appear. I need to check the html entity. I’m not to familiar with twitters api but maybe it’s just a small php encoding problem.

Viewing 2 posts - 1 through 2 (of 2 total)

The topic ‘Twitter Feed: Apostrophes in Internet Explorer’ is closed to new replies.