WordPress.org

Ready to get started?Download WordPress

Forums

WPBook
[resolved] fwright Warning errors on publish (4 posts)

  1. hankman2k
    Member
    Posted 3 years ago #

    WP URL: http://www.hankandheather.com
    Application: http://apps.facebook.com/wpbookhandh
    WPBook ver 2.2.1

    After a long fight it looks like *almost* everything is working. All of the tests come back correctly. My token says it has been stored and A publish actually posts to facebook! YAY.

    However, I'm getting the following errors on publish:

    Warning: fwrite(): supplied argument is not a valid stream resource in /home/wrdwdvj/public_html/wp-content/plugins/wpbook/includes/publish_to_facebook.php on line 67
    ...
    Warning: fclose(): supplied argument is not a valid stream resource in /home/wrdwdvj/public_html/wp-content/plugins/wpbook/includes/publish_to_facebook.php on line 372

    Warning: Cannot modify header information - headers already sent by (output started at /home/wrdwdvj/public_html/wp-content/plugins/wpbook/includes/publish_to_facebook.php:67) in /home/wrdwdvj/public_html/wp-includes/pluggable.php on line 897

    As I said the post is showing up on Facebook, including a random image from my blog (didn't happen before). I've turned off debugging and the error persists. I've read the previous thread about the error, but it would appear that ver 2.2.1 should have fixed that.

    Any help is greatly appreciated!

  2. johneckman
    Member
    Plugin Author

    Posted 3 years ago #

    Can you install the development version?

    (On http://wordpress.org/extend/plugins/wpbook/download/ there is a version at the bottom marked "development")

    I had tried to clean up all the references to the $fp file pointer for the debug file in 2.2. but apparently I was too aggressive and introduced some issues - they should be fixed in the development version, which I hope to push as 2.2.2 later today or this weekend. Would love it if you could validate that the development version does fix these issues on your install.

  3. hankman2k
    Member
    Posted 3 years ago #

    It worked great! No errors and all was well. You're a rock star!

    My only question is, wpbook is now grabbing and inserting the random image from my WPG2 homepage plugin if there isn't an image in the blog post. I can deal, it's just not optimal. Am I missing something in the config that's different?

    Again, thanks a ton. I look forward to the update this weekend.

    -Hank

  4. johneckman
    Member
    Plugin Author

    Posted 3 years ago #

    No, you're not missing anything.

    WPBook looks for a "featured image" (aka Post Thumbnail) set in WordPress for the post being published. If it finds one, it uses that image as what Facebook calls an "attachment" to the post on the profile/page/group's wall.

    If WPBook doesn't find a featured image, it posts to the wall without one.

    In that latter case, Facebook seems to go look up the url being referred to and scrape an image from that url, but it more or less chooses that image at random.

    I'm not sure what WPBook should do in this case. You can "hint" Facebook using metadata - og:image in this case - but that has to be present in the <head> of whichever URL FB looks at, which might be inside the app but might be the external permalink?

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags