WordPress.org

Forums

Jetpack by WordPress.com
[resolved] Malfunction with PHP upgrade (22 posts)

  1. MJEG
    Member
    Posted 1 year ago #

    My web hosting provider recently forced me to upgrade from PHP 2.2 to 2.4. With this upgrade Jetpack causes my theme to malfunction. The theme works fine when I disable Jetpack.

    The error occurs when I open a post from the home page. It causes the image in the post to show a few times at the top of the page with the rest of the page loading below this so that I must scroll down to see the page as it is supposed to be seen.

    any help appreciated.

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

  2. MJEG
    Member
    Posted 1 year ago #

    I have been forced to disable Jetpack until this issue can be resolved. Sadly that also means I also lose all of the functionality that comes with Jetpack as I now use Jetpack to replace many of the different plugins I used to use individually.

  3. MJEG
    Member
    Posted 1 year ago #

    I have reactivated Jetpack so that anyone who can help may see the issue themselves.

    My site is located at http://photography.greff.co

    Thank you.

  4. MJEG
    Member
    Posted 1 year ago #

    sorry should say PHP upgrade from 5.2 to 5.4 above.

  5. WPyogi
    Forum Moderator
    Posted 1 year ago #

    Do you have the same issue on a default theme?

    Have you tried deactivating your other plugins?

  6. MJEG
    Member
    Posted 1 year ago #

    I have tried deactivating all the other plugins; it only occurs when the Jetpack plugin is activated.

    I have deleted and re-installed both Jetpack and the Theme. The issue persists. The issue does not occur with a default theme.

  7. WPyogi
    Forum Moderator
    Posted 1 year ago #

    The issue does not occur with a default theme.

    I see you already have a thread on the theme's forum - looks like it hasn't been updated in a more than a year, so that's likely the problem.

  8. Jeremy Herve
    Happiness Engineer
    Plugin Author

    Posted 1 year ago #

    For reference, here is the other thread about this problem.

    I installed and activated Picturesque on a test site, and couldn't reproduce the issue.
    Have you made some changes to the theme since you installed it? If so, could you try to install a fresh version of the theme, and let us know if it helps?

    If you still experience issues, you might want to comment add_theme_support lines in the functions.php file, one at a time, and see if one of them creates the problem. To comment a specific line, at // in front of it. You can look at line 57 for an example:

    //add_theme_support( 'hybrid-core-seo' );

    Let us know if you find out more about the problem!

  9. MJEG
    Member
    Posted 1 year ago #

    Thank you for your reply. I am baffled by the issue.

    I then deleted the theme. I went so far as to delete all of the files via FTP client to ensure the entire theme folder was deleted from the server. I then did a fresh install of the theme via wordpress (Where I searched for the theme in wordpress and had it download and install the files directly from wordpress.org. The issue persisted.

    I created another test site on my network to check if the issue would also occur there. At first the issue did not occur there when using the theme and Jetpack. However once I connected Jetpack to wordpress.com the issue also began to occur.

  10. MJEG
    Member
    Posted 1 year ago #

    I also completely deleted jetpack via FTP so that all of it's files were removed, and did a clean re-install of Jetpack. Once I reinstalled jetpack the problem returned. When Jetpack is no activated there is not issue. These are clean installs of both the theme and the plugin. Zero alterations.

    The issue also occurs with my Test Site I just created on my network. There are no other plugins running on this test site. All I have done is create one post for which the issue occurs.

  11. Jeremy Herve
    Happiness Engineer
    Plugin Author

    Posted 1 year ago #

    Could you try to comment out the theme features as I mentioned earlier, and let me know if you can narrow down the issue to a specific feature?

    You might want to do the same with Jetpack: deactivate each Jetpack module, one at a time, and let me know if the issue disappears when you deactivate a specific module.

  12. MJEG
    Member
    Posted 1 year ago #

    A few things I have noticed. The issue only occurs on posts where I have uploaded the image using the media upload for that post and that is the only post with the image. Or also it will occur if I upload and image to the image library, it will occur on the post where I use the image the first time. If I insert that image into a second post the issue will not occur.

    If I create a new image post, and insert in that post an image which has been uploaded elsewhere, the issue does not occur. Therefore the two posts are essentially identical. The only difference is that in one I uploaded the image to that post and the image is therefore "linked" to that post somehow, it occurs on the post it is linked to. but does not occur on the second post which is identical otherwise.

    For example: The first place I use this image HERE the issue occurs. The second time I use that image HERE. The issue does not occur. The two posts are identical otherwise.

    The issue does not occur on posts which only contain a gallery.

  13. MJEG
    Member
    Posted 1 year ago #

    I attempted to comment on each of the theme features. A few caused the theme to not function at all, others made no difference with the issue. I will see about doing the same with jetpack.

  14. MJEG
    Member
    Posted 1 year ago #

    I have worked through deactivating the Jetpack Modules. I have narrowed the issue down to the "Sharing" and "Publicize" modules. If either of these two are Activated, then the issue occurs. If they are both deactivated the issue goes away.

  15. MJEG
    Member
    Posted 1 year ago #

    Thank you for your assistance thus far. Much appreciated.

  16. MJEG
    Member
    Posted 1 year ago #

    I have further narrowed it down to being an issue with the featured image. Where I noted above that the issue did not occur when I created an identical post with an image previously used. Once I set the featured image for that post; the issue will occur. (As long as the "Publicize" and "Sharing" modules are activated, if deactivated the issue resolves)

  17. MJEG
    Member
    Posted 1 year ago #

    I am noticing that there are a lot of threads with regards to the Publicize module recently. I am thinking that perhaps this issue may not have anything to do with my forced PHP upgrade but with the recent Jetpack update. The current version was updated 11-28, whereas my last blog post was on 11-24 and everything was working at that time. Between that time and now my blog underwent the forced PHP upgrade and I updated Jetpack. Considering the issues others are posting with regards to Publicize this may just be a Publicize issue.

  18. Jeremy Herve
    Happiness Engineer
    Plugin Author

    Posted 1 year ago #

    Could you try to add the following line to your theme's functions.php file, and let me know if it helps?

    add_filter( 'jetpack_enable_open_graph', '__return_false', 99 );

  19. MJEG
    Member
    Posted 1 year ago #

    I have attempted to add the above line. I don't really want to mess with the core theme files. I don't know enough about code that as a general rule I don't mess with them. Thus I have setup a child theme.

    I have added the line in the code of the child theme as shown here. This is the only change I have made to the theme. The child theme other than being setup as one has made no changes to the original theme.

    Hopefully I have done this correctly. When I do this I just get a blank page on the website. Similarly I wasn't sure if it was because I was creating this functions.php file wrong I also attempted to add the line you suggested to the core file with the same result (a blank webpage). Thus I removed it from the core theme files.

    <?php
    /**
     * This is your child theme functions file.  In general, most PHP customizations should be placed within this
     * file.  Sometimes, you may have to overwrite a template file.  However, you should consult the theme
     * documentation and support forums before making a decision.  In most cases, what you want to accomplish
     * can be done from this file alone.  This isn't a foreign practice introduced by parent/child themes.  This is
     * how WordPress works.  By utilizing the functions.php file, you are both future-proofing your site and using
     * a general best practice for coding.
     *
     * All style/design changes should take place within your style.css file, not this one.
     *
     * The functions file can be your best friend or your worst enemy.  Always double-check your code to make
     * sure that you close everything that you open and that it works before uploading it to a live site.
     *
     * @package MyLifeChild
     * @subpackage Functions
     */
    
    /* Adds the child theme setup function to the 'after_setup_theme' hook. */
    add_action( 'after_setup_theme', 'picturesque_child_theme_setup', 11 );
    
    /**
     * Setup function.  All child themes should run their setup within this function.  The idea is to add/remove
     * filters and actions after the parent theme has been set up.  This function provides you that opportunity.
     *
     * @since 0.1.0
     */
    function picturesque_child_theme_setup() {
    
    add_filter( 'jetpack_enable_open_graph', '__return_false', 99 );
    
    	/* Get the theme prefix ("picturesque"). */
    	$prefix = hybrid_get_prefix();
    
    	/* Example action. */
    	// add_action( "{$prefix}_header", 'picturesque_child_example_action' );
    
    	/* Example filter. */
    	// add_filter( "{$prefix}_site_title", 'picturesque_child_example_filter' );
    
    }
    
    ?>
  20. Jeremy Herve
    Happiness Engineer
    Plugin Author

    Posted 1 year ago #

    Let's try something else then. Could you download this zip file:
    http://i.wpne.ws/SnJq

    Then go to Plugins > Add New > Upload in your dashboard, and activate this small plugin.

    Let me know if it helps.

  21. MJEG
    Member
    Posted 1 year ago #

    The plugin seems to have resolved the issue. Thank you.

  22. Jeremy Herve
    Happiness Engineer
    Plugin Author

    Posted 1 year ago #

    Alright. I'm still not sure why I couldn't reproduce the issue, though, even when both of us downloaded and installed Picturesque from the themes repository.

    Would you mind contacting me via email, and mention this forum thread? I'd love to run a few tests on your site in order to understand the problem, and then fix it so you can enable the Open Graph meta tags back on your site.

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Jetpack by WordPress.com
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic