src/UI/Output.php
public static function getUtilUrl($path)
    {
        global $CFG;
        if ( isset($CFG->utilroot) ) {
            return $CFG->utilroot.$path;
        }

        // From wwwroot
        $path = str_replace('.php','',$path);
        $retval = $CFG->wwwroot . '/util' . $path;
        return $retval;

        // The old way from "vendor"
        // return $CFG->vendorroot.$path;
    }
public static function getUtilUrl($path)
    {
        global $CFG;
        if ( isset($CFG->utilroot) ) {
            return $CFG->utilroot.$path;
        }

        // From wwwroot
        $path = str_replace('.php','',$path);
        $retval = $CFG->wwwroot . '/util' . $path;
        return $retval;

        // The old way from "vendor"
        // return $CFG->vendorroot.$path;
    }
public static function getUtilUrl ( $ path ) { global $ CFG ; if ( isset ( $ CFG -> utilroot ) ) { return $ CFG -> utilroot . $ path ; } // From wwwroot $ path = str_replace ( '.php' , '' , $ path ) ; $ retval = $ CFG -> wwwroot . '/util' . $ path ; return $ retval ; // The old way from "vendor" // return $CFG->vendorroot.$path; }
getUtilUrl - Get a URL in the utility script space - does not add session

@param $path - The path of the file - should start with a slash.
getUtilUrl - Get a URL in the utility script space - does not add session