コード例 #1
0
		public HeaderAndFooterTemplateDeclaration(TemplateDeclarationConfig cfg, XmlElement el)
			: base(el)
		{
			this.header = el.GetAttribute("header");
			this.footer = el.GetAttribute("footer");

			Regex rxIsRoot = new Regex("^[/~]");
			if (!rxIsRoot.IsMatch(this.header))
				this.header = cfg.BaseDirectory + "/" + this.header;
			if (!rxIsRoot.IsMatch(this.footer))
				this.footer = cfg.BaseDirectory + "/" + this.footer;
		}
コード例 #2
0
        public HeaderAndFooterTemplateDeclaration(TemplateDeclarationConfig cfg, XmlElement el)
            : base(el)
        {
            this.header = el.GetAttribute("header");
            this.footer = el.GetAttribute("footer");

            Regex rxIsRoot = new Regex("^[/~]");

            if (!rxIsRoot.IsMatch(this.header))
            {
                this.header = cfg.BaseDirectory + "/" + this.header;
            }
            if (!rxIsRoot.IsMatch(this.footer))
            {
                this.footer = cfg.BaseDirectory + "/" + this.footer;
            }
        }
コード例 #3
0
		static TemplatedPage()
		{
			templates = (TemplateDeclarationConfig) ConfigurationSettings.GetConfig("suprifattus.templates/templates");
			mappings = (TemplateMappingConfig) ConfigurationSettings.GetConfig("suprifattus.templates/mappings");
		}