WordPress.org

Ready to get started?Download WordPress

Forums

[Plugin: Google Calendar Feed Parser] If your host disables file_get_contents for URLs... (1 post)

  1. Anonymous
    Unregistered
    Posted 6 years ago #

    REPLACE:
    $xmlstr = file_get_contents($feed_url);

    ------------

    WITH:
    $ch = curl_init();
    $timeout = 5; // set to zero for no timeout
    curl_setopt ($ch, CURLOPT_URL, $feed_url);
    curl_setopt ($ch, CURLOPT_RETURNTRANSFER, 1);
    curl_setopt ($ch, CURLOPT_CONNECTTIMEOUT, $timeout);
    $xmlstr = curl_exec($ch);
    curl_close($ch);

    ------------

    Justin, if you see this, I tried with 3 different browsers to comment on the feed parser post (and the post about your spam filter) and was unable to do so.

    Good work on the plugin though!

    http://wordpress.org/extend/plugins/google-calendar-feed-parser/

Topic Closed

This topic has been closed to new replies.

About this Topic

  • RSS feed for this topic
  • Started 6 years ago by Anonymous
  • This topic is not a support question
  • WordPress version: 2.6