コード例 #1
0
        protected void Page_Load(object sender, System.EventArgs e)
        {
            this.fckEditor.BasePath = this.Page.ResolveUrl("~/Support/FCKeditor/");
            this._module = base.Module as StaticHtmlModule;

            if (! this.IsPostBack)
            {
                StaticHtmlContent htmlContent = this._module.ContentItemService.FindContentItemsBySection(this._module.Section).FirstOrDefault()
                                                ?? new StaticHtmlContent();

                if (htmlContent != null)
                {
                    tbTitle.Text = htmlContent.Title;
                    this.fckEditor.Value = htmlContent.Content;
                }
                else
                {
                    this.fckEditor.Value = String.Empty;
                }
            }

            //To DISPLAY template styles in editor
            fckEditor.EditorAreaCSS = UrlHelper.GetApplicationPath() + this.Node.Template.BasePath + "/css/editor_" + this.Node.Template.Css;
            //To ADD template styles in editor DropDown List
            fckEditor.StylesXmlPath = UrlHelper.GetApplicationPath() + this.Node.Template.BasePath + "/css/fckstyles.xml";
        }
コード例 #2
0
 protected void Page_Load(object sender, System.EventArgs e)
 {
     this._module = base.Module as StaticHtmlModule;
     if (! this.IsPostBack)
     {
         StaticHtmlContent shc = this._module.GetContent();
         if (shc != null)
         {
             this.txtEditor.Text = shc.Content;
         }
         else
         {
             this.txtEditor.Text = String.Empty;
         }
     }
 }
コード例 #3
0
        protected void Page_Load(object sender, System.EventArgs e)
        {
            this.fckEditor.BasePath = this.Page.ResolveUrl("~/Support/FCKeditor/");
            this._module = base.Module as StaticHtmlModule;

            if (! this.IsPostBack)
            {
                StaticHtmlContent shc = this._module.GetContent();
                if (shc != null)
                {
                    this.fckEditor.Value = shc.Content;
                }
                else
                {
                    this.fckEditor.Value = String.Empty;
                }
            }
        }