We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 53063
    • 4 Posts
    Problem
    All private pages are always hidden in the frontend, even if the user is allowed to have access to them.


    Solution
    Replace the lines 410-421 in wayfinder.inc.php (section "build query") with:
    // build query
                if($modx->isFrontend()) {
                    if(!$this->_config['showPrivate']) {
                        $access = "sc.privateweb=0";
                    }
                }
                else {
                    $access = sprintf("1='%s' OR sc.privatemgr=0", $_SESSION['mgrRole']);
                }
                if(($access and $docgrp)) $access .= sprintf(' OR dg.document_group IN (%s)', $docgrp);
                if($access) $access = "AND({$access})";


    In addition, wayfinder must be called with [! ... !].

    Sorry, I did not know, where I should write otherwise.

    This question has been answered by iusemodx. See the first response.

    • discuss.answer
      • 13226
      • 953 Posts
      This probably has to do with this and the modifications can be found here