We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 36671 ☆ A M B ☆
    • 120 Posts
    I am using getPage with getResources for an online shop catalogue page. Initially everything worked fine. However, yesterday I noticed that the getPage call no longer worked and the catalogue pages were blank.

    I checked in Package Management and getPage was "uninstalled". I don't know if I accidentally uninstalled it while I was installing some other packages the day before. However, I reinstalled it but the call still returns blank. Has anybody else ever come across this issue? I've cleared the cache etc. but no luck. I haven't touched any other site code in the last couple of days so I'm completely stumped.

    Any suggestions appreciated!

    Just in case, here is my code:

    Catalogue Page Template


    [[$headShop]]
    
    <link rel="stylesheet" href="http://modx.com/assets/components/discuss/themes/modx/css/index.css" type="text/css" />
    <link rel="stylesheet" href="http://modx.com/assets/components/discuss/themes/modx/css/jquery-ui-1.8.16.custom.css" type="text/css" />
    <script type="text/javascript" src="http://modx.com/assets/components/discuss/themes/modx/js/jquery-1.6.2.min.js"></script>
    <script type="text/javascript" src="http://modx.com/assets/components/discuss/themes/modx/js/jquery.scrollTo-min.js"></script>
    <script type="text/javascript" src="http://modx.com/assets/components/discuss/themes/modx/js/jquery-ui-1.8.16.custom.min.js"></script>
    <script type="text/javascript" src="http://modx.com/assets/components/discuss/themes/modx/js/discuss.js"></script>
    <script type="text/javascript" src="http://modx.com/assets/components/discuss/themes/modx/js/sh/shCore.js"></script>
    <script type="text/javascript" src="http://modx.com/assets/components/discuss/themes/modx/js/sh/shAutoloader.js"></script>
    <script type="text/javascript" src="http://modx.com/assets/components/discuss/themes/modx/js/sh/shDiscuss.js"></script>
    <script type="text/javascript" src="http://modx.com/assets/components/discuss/themes/modx/js/dis.sticky.js"></script>
    <script type="text/javascript">// <![CDATA[
    DIS.url = "/";DIS.shJsUrl = "http://modx.com/assets/components/discuss/themes/modx/js/sh/";DIS.config.connector = "http://modx.com/assets/components/discuss/connector.php"
    // ]]></script>
    <script type="text/javascript" src="http://modx.com/assets/components/discuss/themes/modx/js/dis.post.modify.js"></script>
    <script type="text/javascript" src="http://modx.com/assets/components/discuss/themes/modx/js/dis.post.buttons.js"></script>
    </head>
    
    <body class="category">
    
        <div class="dividerRow"></div>
            
        [[$header]]
            
        <div class="dividerRow"></div>
    
        <div id="headerImage" class="container clearfix">
    
            <img class="auto" src="[[*header-image]]" alt="[[*header-image-alttext]]" />
    
        </div> <!-- end container - headerImage -->
    
        <div id="mainContent" class="container">
    
            [[$navSecondary]]
    
            [[$productGridCall]]    
    
        </div> <!-- end container - navSecondary and featuredProducts2x4 --> 
            
        [[$socialBar]]
    
        [[$footer]]
    
    <!-- End Document
    ================================================== -->
    <script type="text/javascript">
            var DISModifyPost = $(function() {
                DIS.config.attachments_max_per_post = 5;
                DIS.DISModifyPost.init({
                    attachments: 1
                });
            });</script>
    </body>
    </html>
    




    productGridCall

    <div id="productGrid" class="twelve columns">
        <div class="clearfix">
        [[!getPage?
           &elementClass=`modSnippet`
           &element=`getResources` 
           &parents=`[[*id]]`
           &limit=`16` 
           &showHidden=`1`
           &tpl=`productGridTpl`
           &tplFirst=`productGridTplAlpha` 
           &tpl_n4=`productGridTplOmega`
           &tpl_5=`productGridTplAlpha`
           &tpl_9=`productGridTplAlpha`
           &tpl_13=`productGridTplAlpha`
           &includeTVs=`1`
           &sortby=`menuindex`
           &sortdir=`ASC` 
        ]]
    
        <div class="paging">
            <ul class="pageList">
                [[!+page.nav]]
            </ul>
        </div>
        </div>
    </div> <!-- end productGrid -->
    




    This is all that ends up in my HTML output:

      <div id="productGrid" class="twelve columns">
        <div class="clearfix">
        
    
        <div class="paging">
            <ul class="pageList">
                
            </ul>
        </div>
        </div>
    </div> <!-- end productGrid -->
    
    [ed. note: intandem last edited this post 14 years ago.]
      • 28042 ☆ A M B ☆
      • 24,524 Posts
      Try uninistalling it, completely remove it, then download it and install it again.
        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
        • 36671 ☆ A M B ☆
        • 120 Posts
        Have tried that but still no luck. Just tried to rewrite the call with getResources instead and it also doesn't return anything. The thing that stumps me is that it was all working perfectly fine. Anyway, I currently have someone else look over it with a fresh pair of eyes ...


        Ah, just got a call from them. Turns out the getResources snippet was somehow corrupted. Still a mystery why unless the CodeMirror installation was the cause of that??? Anyway, uninstalling getResources and reinstalling it seems to have sorted it out.

        Thanks for your reply!