WordPress.org

Ready to get started?Download WordPress

Forums

Jetpack by WordPress.com
[resolved] Jetpack + Youtube embeds (30 posts)

  1. dbwilldo
    Member
    Posted 1 year ago #

    Pre 3.5, this problem did not exist.

    You can see the problem on this post, but I'm getting PHP errors:

    Warning: stripos() [function.stripos]: needle is not a string or an integer in /home/donburn/public_html/wp-includes/functions.php on line 658
    
    Warning: stripos() [function.stripos]: needle is not a string or an integer in /home/donburn/public_html/wp-includes/functions.php on line 661

    These errors show up on any post with a Youtube video embedded. The weird part is that the error does not show up on the main blog page or archive index. See no errors here. The other weird part is that the error is pointing at a core WP file, not something related to any specific plug-in or file in my theme.

    I have disabled all plugins, the error goes away. I turn all of my plugins back on except Jetpack, no problem. I turn Jetpack on, it comes back.

    I have also tested this using Twenty Twelve and got the exact same problem.

    I have turned off shortcode embeds, but the issue is still there.

    It's only my personal site and am game to trying anything anyone can think of to fix the issue.

    http://wordpress.org/extend/plugins/jetpack/

  2. Jeremy Herve
    Happiness Engineer
    Plugin Author

    Posted 1 year ago #

    Could you let me know how you embedded these videos?

    Did you use the shortcode, or did you just paste the video URL on a separate line?

    I notice that one of the videos appears on that blog post. Is there a difference between this video and the others?

  3. dbwilldo
    Member
    Posted 1 year ago #

    The one I used as an example is using the long version of the Youtube embed code. this one is using the short version of the Youtube embed code.

    I've tried using shortcodes and the same thing happens. I haven't tried with the URL only.

  4. dbwilldo
    Member
    Posted 1 year ago #

    Saw the update to Jetpack and was excited. But it didn't fix my issue.

    Guess it's back to the drawboard for me to make sure it's not my WP installs.

  5. Jeremy Herve
    Happiness Engineer
    Plugin Author

    Posted 1 year ago #

    Could you try to insert the video URL on a separate line, without using any shortcodes, like so:

    http://youtu.be/v3W-W_JaKtk

    I hope this helps.

  6. dbwilldo
    Member
    Posted 1 year ago #

    Did that, no video shows up and the error code is still there.

    http://donburnside.com/recipe-chicken-waffles/

    I tried pasting the code in using the text and visual editor. Nothing.

    Turned shortcodes back on. Didn't help. Turned them off, nothing.

    When I paste the url directly into a post, the video doesn't even show up and I thought that was a new feature of 3.5. I'm going to try to do a fresh install of WP and see if that helps.

  7. dbwilldo
    Member
    Posted 1 year ago #

    Reinstalled WP though the dashboard, didn't help. Copied new files from a fresh download via FTP, no help either.

  8. Jeremy Herve
    Happiness Engineer
    Plugin Author

    Posted 1 year ago #

    Could you check if WP_DEBUG is set to true in your wp-config.php file? If so, could you set it to false on your production site?

    If that doesn't help, could you try to disable the sharing module in Jetpack? You can find out how to disable a module here:
    http://jetpack.me/support/#turn-off-jetpack-modules

  9. Jeremy Herve
    Happiness Engineer
    Plugin Author

    Posted 1 year ago #

    Could you also make a screenshot of the Settings > Sharing page in your dashboard? It might give us some important information so we can reproduce the problem.
    Thanks!

  10. dbwilldo
    Member
    Posted 1 year ago #

    WP_DEBUG wasn't listed in my wp-config.php, so I did that. Set it to true first to make sure it was working, then set it to false. Errors still on the screen.

    I disabled the sharing module and that removed the error. I used the youtube shortcode to embed a video, still error free.

    Video embed via shortcode. And the screenshot is here.

    Let me know what else I can do to help, including access to the site via wp-admin or ftp.

  11. dbwilldo
    Member
    Posted 1 year ago #

    I was using the Artiss YouTube Embed plugin. I long ago removed it, but there were a few bits of it left in the database. I removed those bits (and double checked that the files were removed) and turned sharing back on. It didn't help.

  12. dbwilldo
    Member
    Posted 1 year ago #

    Finally, I went through all of my plugins and disabled them except for Jetpack (with sharing enabled). The error still existed. I also tried with the Twenty Ten and Twenty Twelve themes, and the error still existed.

    I can only replicate this on 1 site and am starting to think it's an issues with my theme. But this one is new to me. Could it be caused by custom posts or default WordPress features like custom header or background?

  13. Christopher Finke
    Design Engineer at Automattic
    Plugin Author

    Posted 1 year ago #

    Have you tried disabling all of the Jetpack modules one-by-one and seeing which one causes the error to disappear? This can take a few minutes, but it would be very helpful.

  14. Christopher Finke
    Design Engineer at Automattic
    Plugin Author

    Posted 1 year ago #

    Also, is the one site that you are having this problem on on a different host than your other sites? Is it running on a different version of PHP?

  15. dbwilldo
    Member
    Posted 1 year ago #

    Nothing but blue buttons on my jetpack. I checked after disabling each one, error did not go away until I disabled sharing.

    Same theme, different server, same issues. Same version of php. Different theme (barely different), same server, no issues.

    I'm trying to find a few minutes to replicate this on my wpengine account with this theme to see if I can replicate it. I'm starting to think that this might be an issue with a plugin that was installed and did not completely remove itself when I uninstalled it.

  16. Christopher Finke
    Design Engineer at Automattic
    Plugin Author

    Posted 1 year ago #

    There is at least one other user experiencing the same issue (http://wordpress.org/support/topic/plugin-error-12?replies=10#post-3615666), so it's probably not specific to your theme, but any information you can dig up is very much appreciated.

  17. dbwilldo
    Member
    Posted 1 year ago #

    I just installed this theme on my wpengine account and enabled both shortcode embeds and sharing. Even added my Facebook and Twitter accounts. No errors are showing up.

    I do manage another site that has the Artliss embed plugin installed, but it's not having this issue at all. I'm completely baffled.

  18. dbwilldo
    Member
    Posted 1 year ago #

    I did follow the link posted on that other thread where the person said the issue goes away if a featured image is selected. So, I did that.

    Boom. Errors gone.

  19. Christopher Finke
    Design Engineer at Automattic
    Plugin Author

    Posted 1 year ago #

    Very strange. The featured image thing adds yet another level of interestingness...

  20. dbwilldo
    Member
    Posted 1 year ago #

    OK, just removed featured image support from my functions.php and removed the featured image from my test post and the errors are still gone.

    I think that might be the link. Something with featured images might be causing the issue.

  21. dbwilldo
    Member
    Posted 1 year ago #

    This is even weirder. I put the Featured Image code back into my functions.php and the error is *still* gone. A real head scratcher this is.

    (Also, would be handy if there was a dev option for jetpack so it would work on local test machines that don't allow inbound traffic). :D

  22. Christopher Finke
    Design Engineer at Automattic
    Plugin Author

    Posted 1 year ago #

    If you still have a post where you can get the error to appear, can you try adding the following line of code to modules/sharedaddy/sharing-sources.php after line 1138?

    if ( ! $thumb ) continue;

    I'm thinking that a plugin you used to have installed is making it seem that posts have featured images even when they don't, and this discrepancy is causing the problem.

  23. Christopher Finke
    Design Engineer at Automattic
    Plugin Author

    Posted 1 year ago #

    Whoops, that should have been:

    if ( ! $thumb ) return '';

  24. dbwilldo
    Member
    Posted 1 year ago #

    Ok, error regenerated. Here goes nothing!

  25. dbwilldo
    Member
    Posted 1 year ago #

    Well, would you look at that.

    Boom.

  26. Christopher Finke
    Design Engineer at Automattic
    Plugin Author

    Posted 1 year ago #

    Can you confirm that if you remove the line you added, the error returns?

  27. dbwilldo
    Member
    Posted 1 year ago #

    Confirmed. Lined removed, error returns.

  28. Christopher Finke
    Design Engineer at Automattic
    Plugin Author

    Posted 1 year ago #

    Awesome. You can leave the line there; it will be included in the next Jetpack update. Thanks so much for your help with this.

    An aside: if you feel like investigating further, the question at the root of the problem is: why does has_post_thumbnail() return true but wp_get_attachment_image_src() returns false? My guess is data leftover from an uninstalled plugin, but I have nothing to back that up.

  29. dbwilldo
    Member
    Posted 1 year ago #

    That could be possible and makes sense. On both sites I have used an auto featured image to generate the required featured image for the theme. I ended up disabling that plugin after it did it's thing.

    But I'll poke around some more. Glad to help!

  30. afanasyevich
    Member
    Posted 1 year ago #

    has_post_thumbnail() return true that caused error not only while plugins define "bulk" featured image but also while select new theme but old theme define this "bulk" featured image and its data leftover inside database. wp_get_attachment_image_src() return false, it happens on imported post from another wordpress site.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic