We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 29110
    • 17 Posts
    Modx Revo 2.2.2-pl
    Articles 1.6.3 pl

    Fatal error: Call to a member function get() on a non-object in myserveraddress/htdocs/VSF_modx/core/cache/includes/elements/modsnippet/7.include.cache.php on line 21

    Modx site on 'live' server (for testing purposes and client feedback) was working fine.
    Installed Articles fine.
    Create Article resource called rather unimaginatively 'blog' fine.
    Manage Articles and create first article fine.
    Publish article, clear cache and check site in Firefox 14.0.1 and get the fatal error?
    Help please ?

    Thanks in advance!

    Syrah
      • 29110
      • 17 Posts
      I should add that I can preview the article from within manager but I can no longer launch the site !
        • 28042 ☆ A M B ☆
        • 24,524 Posts
        Physically remove all the folders in the core/cache folder.
          Studying MODX in the desert - http://sottwell.com
          Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
          Join the Slack Community - http://modx.org
          • 29110
          • 17 Posts
          Thanks sottwell - will try that now.
            • 29110
            • 17 Posts
            All the folders in the core/cache folder removed - but alas the fatal error remains.
              • 29110
              • 17 Posts
              So, when I turn off the Snippet call referred to in the Fatal Error said error is no more. So, can anyone give me an idea as to what in Articles (or my Snippet) is causing this error ? Not sure what to do now.

              The line of code referred to in the Fatal Error is :

              $listItem = $resource->get('menutitle');


              If this is empty I'm returning the pagetitle instead in a the next couple of lines.

              Why would this innocuous line cause a conflict with Articles ?

              Anyone ?

              Thanks hugely in advance for any help you can offer !!!

              Syrah

                • 29110
                • 17 Posts
                I wondered if it was a variable conflict and so change the variable name in the line. Error remained. I guess I have to drop Articles and do it the clunky way… Damn !
                  • 28042 ☆ A M B ☆
                  • 24,524 Posts
                  Try determining which snippet is #7, then remove it completely in Package manager and re-download and install it again. It looks like something got corrupted somewhere.
                    Studying MODX in the desert - http://sottwell.com
                    Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
                    Join the Slack Community - http://modx.org
                    • 29110
                    • 17 Posts
                    Thanks again for getting back to me. You really are the best ! I've taken the decision to remove Articles and have made good progress doing it the clunky way. I'll come back to Articles for another project.

                    Thanks again for your helpful suggestions.

                    Syrah