code: def _load_templates(self, config):
          
          # definition of the template directory
          self.template_dir = self._get_param(
              'resources',
              'templates.dir',
              config
              )
          cherrypy.log.error(
              msg="loading templates from dir '%(dir)s'" %
                  {'dir': self.template_dir},
              severity=logging.DEBUG
          )
          # preload templates
          self.temp_lookup = lookup.TemplateLookup(
              directories=self.template_dir, input_encoding='utf-8',
              default_filters=['unicode', 'h']
              )
          # load each template
          self.temp = {}
          for t in ('index.tmpl', 'error.tmpl', 'login.tmpl', '404.tmpl',
                    'searchadmin.tmpl', 'searchuser.tmpl', 'adduser.tmpl',
                    'roles.tmpl', 'groups.tmpl', 'form.tmpl', 'selfmodify.tmpl',
                    'modify.tmpl', 'service_unavailable.tmpl'
                    ):
              self.temp[t] = self.temp_lookup.get_template(t)
docs: load templates
          @dict: configuration of ldapcherry