• Resolved mikedunn

    (@mikedunn)


    I’m having two issues I’ll post separately.

    The first is that the timezone offset doesn’t seem to be working for me. I posted a tweet at 10:53AM today (EDT or UTC -4). When it was imported into WordPress, it was set as scheduled to publish at 2:53PM EDT.

    in other words, it seems to be ignoring my WordPress datetime setting.

    https://ww.wp.xz.cn/plugins/import-tweets-as-posts/

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Chandan Kumar

    (@chandanonline4u)

    Yes it is ignoring the WordPress timezone settings. It is using your twitter timezone setting to set published date.

    If you want to set it as per your WordPress Timezone you can customize plugin. Open ‘import-twets-as-posts.php’ file and replace the following code:

    $tweet_post_time = strtotime($tweet->created_at) + $tweet->user->utc_offset;

    To:

    $tweet_time = strtotime($tweet->created_at);
    $wp_offset = get_option('gmt_offset');
    if($wp_offset){
      $tweet_post_time = $tweet_time + ($wp_offset * 3600);
    } else {
      $tweet_post_time = $tweet_time + $tweet->user->utc_offset;
    }

    Hope this will help you.

    Plugin Author Chandan Kumar

    (@chandanonline4u)

    Also added option under plugin’s setting to set tweet publish date as per WordPress timezone in updated version 1.5. Let me know if this works for you.

    Thread Starter mikedunn

    (@mikedunn)

    Just tested. Works great.

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Timezone Offset Issue’ is closed to new replies.