protected static function renderXML($file, $params)
    {
        // check if already loaded
        if (empty(static::$xml[$file])) {
            // load if file not loaded
            static::$xml[$file] = file_get_contents(__DIR__ . '/xml/'.$file.'.xml');
        }

        // build the search and replace arrays
        $search = [];
        $replace = [];

        foreach ($params as $key => $value) {
            $search[] = ':'.$key;
            $replace[] = $value;
        }

        // return the rendered file
        return str_replace($search, $replace, static::$xml[$file]);
    }