Navigation
This is archived content. Visit our new forum.
  • Author
    Posts
  • #735853

    marijn@nuova-it.nl
    Participant

    Trying to get property of non-object in /var/www/comblu-dymgaylis/wordpress/current/wp-content/plugins/cornerstone/includes/integrations/conflict-resolution.php on line 95

    I’m having the same issue with cornerstone and wpml. It’s all updated to the last revisions and I just removed and reinstalled cornerstone.
    Did not help and problems are also back.

    any suggestions?

    #735857

    marijn@nuova-it.nl
    Participant
    This reply has been marked as private.
    #736114

    Jade
    Moderator

    Hi there,

    Thanks for writing. You seem to have missed adding your site URL to the info you have provided.

    Kindly provide us with your FTP details as well so we could check this further.

    Thank you.

    #736129

    marijn@nuova-it.nl
    Participant

    site is seawindadventures.com

    #736132

    marijn@nuova-it.nl
    Participant
    This reply has been marked as private.
    #736509

    Jade
    Moderator

    Hi there,

    Thanks for the details. Please try testing for a plugin conflict. You can do this by deactivating all third party plugins, and seeing if the problem remains. If it’s fixed, you’ll know a plugin caused the problem, and you can narrow down which one by reactivating them one at a time.

    Let us know how it goes.

    #737290

    marijn@nuova-it.nl
    Participant

    Hi,

    Tried that and the issue is, as expected from the errors, with cornerstone and WPML.

    #737748

    Nabeel A
    Moderator

    Hi again,

    I checked your menu section and I am not seeing any error (see attachment) looks like you’ve been able to fix it. Although I noticed one thing that you’re using an old version of WordPress. Please update it to the latest version.

    Thanks!

    #737821

    marijn@nuova-it.nl
    Participant

    Hi,
    WP Debug mode is temporary switched off, that why you did not see it.
    The errors are still there. I will switch debug mode back on so you can see it again.
    I’m not using an old WP version, it’s WP4.4 Just no the very latest 4.4.1 version released couple days ago.

    #738171

    Rue Nel
    Moderator

    Hello There,

    If switching the debug mode to ON displays the PHP Warning, please don’t get alarmed as this is just only a warning and not an error. The warning refers to uninitialize variable which would disappear once the value has been set. Debug mode should only be turn ON when looking for errors and troubleshooting your installation. Most of the time and once your site is live, debug mode should be turn off.

    Hope this explains it.

    #746253

    marijn@nuova-it.nl
    Participant

    Hi, you’re right that it’s not an immediate alarming situation. But as a programmer I know from experience that if you keep ignoring warnings it’ll eventually bite you.
    That’s why I use debug mode on when developing a site and got alarmed by this.

    #746619

    Rad
    Moderator

    Hi there,

    In that case, I’ll just note this for future fixes. Unless it causes malfunctions? Then please provide more information about the issue.

    The code responsible for that is this,

    //WPML Post object usable by multiple filters
    	private function wpml_post () {
    
    		global $post, $sitepress;
    
    		if ( !function_exists('icl_object_id') || !is_callable( array( $sitepress, 'get_current_language' ) ) )
    			return;
    
    		return get_post( icl_object_id( $post->ID, 'post', false, $sitepress->get_current_language() ) );
    	}

    It will check if WPML exist through icl_object_id(), and check if get_current_language() is callable (if valid property of $sitepress). This condition will check if it should continue to line 95. Not sure why it should trigger the warning when the condition results to be invalid.

    Thanks.

    #769212

    sufs
    Participant

    Themeco: I opened the original thread with the same issue. What can be done to get this error to go away now that we know what it is?

    #769816

    Rue Nel
    Moderator

    Hey @sufs,

    Please follow the suggested solution here: https://community.theme.co/forums/topic/trying-to-get-property-of-non-object/#post-746619

    We would be please to know if this has work for you. Thank you.