WordPress.org

Ready to get started?Download WordPress

Forums

WordPress Connect
Sharing on facebook error (7 posts)

  1. LSB Web Design
    Member
    Posted 2 years ago #

    Im using the WordPress connect plugin; however whenever anyone tries to share one of our posts on facebook the title always seems to include the name of our website making it look messy.

    For example i tried to share our post titled BASTILLE - The Laura Palmer EP and it came out like this Dance Yrself CleanBASTILLE - Laura Palmer EP on facebook.

    Any assistance on how i can tidy this up would be appreciated.

    http://www.danceyrselfclean.com/new-music/bastille-laura-palmer-ep

    http://wordpress.org/extend/plugins/wordpress-connect/

  2. scibuff
    Member
    Plugin Author

    Posted 2 years ago #

    Hi,

    the problem is with the og:title value. If you have a look at the source of the html page, it gives the following: <meta property="og:title" content="Dance Yrself CleanBASTILLE - Laura Palmer EP" />

    That is wrong, the site title and the post title should be separated by ' | ' but they're not. I'm a bit puzzled as this works exactly as it is supposed to everywhere else I've looked. By any chance, did you or anyone else modify any of the plugin's code?

    If not, could you please do the following:

    In your dashboard go to

    Plugins > Editor

    then on the right side in the "Select plugin to edit" select "WordPress Connect" and under "Plugin Files" find "wordpress-connect/src/WordpressConnect.php" (should be 5th from the top but may not)

    Click on the file and find the line that looks like this:

    $title = [some stuff here]

    can you tell me the following is there:

    $separator = '|';
    $title = get_bloginfo( 'name' ) . wp_title( $separator, FALSE, 'left' );

    if so, could you scroll down a bit and check that the following is there

    <meta property="og:title" content="<?php echo $title; ?>" />

    intact?

    Thanks

  3. LSB Web Design
    Member
    Posted 2 years ago #

    Thanks for the response.

    No one has edited the plugin code and it seems that both

    $separator = '|';
    $title = get_bloginfo( 'name' ) . wp_title( $separator, FALSE, 'left' );

    and

    <meta property="og:title" content="<?php echo $title; ?>" />

    are present and intact

  4. scibuff
    Member
    Plugin Author

    Posted 2 years ago #

    hmmm, it must be then the output of the wp_title function in your WordPress installation - which version do you have?

    if you want a temporary solution would be to remove the get_bloginfo( 'name' ) . part, so that the line looks like this:

    $title = wp_title( $separator, FALSE, 'left' );

    (you can do this yourself, just delete the unwanted part and hit the "update file" button at the bottom). One more thing, because Facebook caches the open graph data it pulls from pages you may need to reset the cache. This is done by entering the URL (for which you'd like to reset the cache) into the Linturl Facebook Tool (and hit "Debug")

    Meanwhile I'll have a look at the wp_title function and see if I can fix the issue in the next release.

    Thanks

  5. LSB Web Design
    Member
    Posted 2 years ago #

    Ok thanks i tried that however im still seeing the same problem.

    What i did notice though was that when putting my URL in the debugger i get a 503 Response Code.
    Critical Errors That Must Be Fixed
    Bad Response Code URL returned a bad HTTP response code.

  6. samdobrow
    Member
    Posted 1 year ago #

    The WP Connect plugin is not referencing the current page with the Like or Send buttons. Please see the problem on this page:

    http://socialheroics.com/social-heroics-design-challenge/

    The problem is the same all over the site. I need to know how the plugin gets the URL and passes it to Facebook. I've tried hard coding the URL in the short code and still have the same problem.

    I have a bbPress/BudyPress security plugin which redirects logged out users to the (home2) destination page and thought that was causing the problem so I deactivated the security plugin but the problem did not go away with the WP Connect buttons.

    UPDATE: OK, I went off too soon. There was a conflict with a second social sharing plugin activated but not being used. Things seem to work now.

    Any suggestions are appreciated.

  7. scibuff
    Member
    Plugin Author

    Posted 1 year ago #

    The problem is that when the Facebook bot visits the page to gather the information about it (from the og: meta values) it sees an error. You can see what the facebook bot see by using the debugger. For this page the output says that

    Object at URL 'http://socialheroics.com/social-heroics-design-challenge/' of type 'website' is invalid because the domain 'socialheroics.com' is not allowed for the specified application id '397552810305317'. You can verify your configured 'App Domain' at https://developers.facebook.com/apps/397552810305317.

    It seems that you have some sort of settings set for the application which is causing this. Try to create a brand new app just for WP-Connect - http://wp-connect.tomasvorobjov.com/docs/#configure

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic