Support » Plugin: YouTube Channel » No items [Check here why]

Viewing 15 replies - 1 through 15 (of 35 total)
  • I’ve had the same problem–“No items [Check here why]”–pop up within the past week or so after year(s) of trouble free use.

    server: LiteSpeed
    php: 5.4.27
    wp: 3.9.1
    ytc: 2.2.0
    url: http://www.irunfar.com
    title: An iRunFar Featured Video
    channel: iRunFarMedia
    vidqty: 1
    playlist: PLBAA51FB753E60B39
    only_pl: null
    getrnd: null
    maxrnd: 2
    goto_txt: null
    showgoto: null
    showtitle: null
    showvidesc: null
    descappend: …
    videsclen: null
    width: 344
    height: null
    to_show: iframe
    autoplay: null
    lightbox: null
    controls: on
    fixnoitem: on
    ratio: 3
    fixyt: null
    hideinfo: on
    hideanno: on
    themelight: null
    debugon: on
    use_res: 2
    popup_goto: null
    cache_time: 1800
    userchan: null
    enhprivacy: null
    autoplay_mute: null

    Thanks for any help.

    @legarsfred and @irunfar In my test environment (just PHP 5.5.12) I’m getting YTC widget nicely.

    Do you maybe use some page/object caching plugin? Can you disable Cache feed in YTC?

    I’ve disabled YTC caching in both the widget and plugin settings without luck.

    I am using Supercache. I’ve cleared the cache, but receive the same error. I still receive the same error if I disable Supercache entirely.

    Thanks for looking into this.

    Check your email. Cheers!

    I’m experiencing the same problem. I don’t have any cache plugins activated on my WordPress blog.

    This is my debug information from the plugin:

    server: Apache
    php: 5.4.8
    wp: 3.9.1
    ytc: 2.2.0
    url: http://misslisibell.se
    title: Mina senaste YouTube-filmer
    channel: MissLisibell
    vidqty: 5
    playlist: null
    use_res: null
    cache_time: 3600
    only_pl: null
    getrnd: null
    maxrnd: 5
    goto_txt: null
    showgoto: null
    popup_goto: null
    showtitle: on
    showvidesc: null
    descappend: …
    videsclen: null
    width: 220
    height: null
    to_show: thumbnail
    autoplay: null
    controls: null
    fixnoitem: null
    ratio: 3
    fixyt: null
    hideinfo: null
    hideanno: null
    themelight: null
    debugon: on
    userchan: null
    enhprivacy: null
    autoplay_mute: null

    However, the thumbnails show up as expected if I change the “Cache feed” setting to “Do not cache”. On the other hand, I suspect disabling the caching will affect the page load time and server performance negatively.

    @matachi and @irunfar

    Can you please open youtube-channel.php file from plugin’s directory in editor, find string

    'timeout' => 5

    on line 563 and 59, and replace number 2 with 5 or 10, then save changes and try again.

    If after this change you get problem resolved, then we have solution and I’ll release new update with additional option for custom timeout for grabbing cached JSON.

    Cheers,
    Urke

    I set the timeout variable to 10 on both places in youtube-channel.php, but I’m still getting the same error.

    It’s a little hard to follow the flow in the code because you have mixed both tabs and spaces for indentation, and WordPress’s editor shows tabs as 8 spaces wide.

    OK, I think that I found problem with one of your videos. This one https://www.youtube.com/watch?v=15v-KtAaI8U have emoji unicode character at the beginnging and at the end of title. That breaks set_transient() and prevent it to save decodec JSON object to database.

    Try with this development version of YTC, or try to change youtube video title and strip emoji emoticons from title.

    https://www.dropbox.com/s/ll7nrsvk6wbcfkk/youtube-channel-dev.zip

    Cheers

    Is the problem in set_transient or in json_decode? I mean, I would think it’s desirable if they can handle all unicode characters properly.

    set_transient does not work with emoji’s.

    I can serialize and then base64_decode JSON before it’s saved with set_transient, but I wish to avoid false positive alerts from virus scanners (Wordfence, etc).

    If you have other idea, feel free to suggest solution 🙂

    I looked at your patch:

    $json = preg_replace('/🐎/','',$json);

    However, that does obviously only handle the Unicode character 🐎, i.e. U+1F40E. In the Unicode standard there are a lot more emoticons: https://en.wikipedia.org/wiki/Emoji#In_the_Unicode_standard And I guess there would be problems with other Unicode characters as well: https://en.wikipedia.org/wiki/List_of_Unicode_characters

    Well, then only base64_de/encode can solve this:

    set_transient($cache_key, json_decode($json), $instance['cache_time']);
    replaced with
    set_transient($cache_key, base64_encode($json), $instance['cache_time']);

    and

    $json = json_encode($json);
    replaced with
    $json = base64_decode($json);

    I looked at my MySQL database and the collation for the varchar columns in wp_options are all set to utf8_general_ci. I wonder if it might work if I were to change the collation to utf8_unicode_ci instead. Apparently does the latter handle Unicode characters better, although a little slower; according to http://stackoverflow.com/questions/1036454/what-are-the-diffrences-between-utf8-general-ci-and-utf8-unicode-ci.

    I haven’t coded any WordPress plugins so I don’t know the API. But I’m wondering, why do you currently do set_transient($cache_key, json_decode($json), $instance['cache_time']);? Isn’t it possible to store a JSON string as is in the database?

    I tried the code change that you suggested, with base64 encoding the transient data, and it worked fine. However, it feels a bit like a hack. The downsides are the extra encoding/decoding and 33 % storage overhead. Although, I guess neither is noticable.

Viewing 15 replies - 1 through 15 (of 35 total)
  • The topic ‘No items [Check here why]’ is closed to new replies.