To enable the Template Management function of the CuteEditor control, you must set up a managed Template Gallery folder.
This is simply a folder in which you will be placing template files for your
users to use in their content. Create a folder in your application’s root
folder. (For most applications, this is your web server’s root folder, or the
folder where your Visual Studio .NET project file is located.) The folder can
be named something like /templates/, /template or /UserTemplate.
Make sure that the MACHINE/ASPNET user has Read+Write permissions on this
folder and its contents.
You can easily specify the template gallery path using the following
methods:
The security policy file (default.config, admin.config and
guest.config) can be found in the /CuteEditor/Configuration/Security folder. In
security policy file you can find the TemplateGalleryPath
element which contains the template gallery path information within Cute
Editor. By default, it contains the following value:
<security
name="TemplateGalleryPath">~/templates</security>
You can modify the TemplateGalleryPath element to meet your own
requirements.
For example:
Use absolute path:
<security name="TemplateGalleryPath">/templates</security>
Use physical path:
<security name="TemplateGalleryPath">c:\inetpub\wwwroot\templates</security>
C# Example:
//use the app-based path
Editor1.Setting["security:TemplateGalleryPath"]= "~/templates";
//use the absolute path
Editor1.Setting["security:TemplateGalleryPath"]= "/templates";
//use the physical pathor
Editor1.Setting["security:TemplateGalleryPath"]= @"c:\inetpub\wwwroot\templates";
//use the app-based path
Editor1.SetSecurityTemplateGalleryPath= "~/templates";
//use the absolute path
Editor1.SetSecurityTemplateGalleryPath= "/templates";
//use the physical path
Editor1.SetSecurityTemplateGalleryPath= @"c:\inetpub\wwwroot\templates";
VB Example:
//use the app-based path
Editor1.Setting("security:TemplateGalleryPath")= "~/templates"
//use the absolute path
Editor1.Setting("security:TemplateGalleryPath")= "/templates"
//use the physical pathor
Editor1.Setting("security:TemplateGalleryPath")= "c:\inetpub\wwwroot\templates"
//use the app-based path
Editor1.SetSecurityTemplateGalleryPath = "~/templates"
//use the absolute path
Editor1.SetSecurityTemplateGalleryPath = "/templates"
//use the physical path
Editor1.SetSecurityTemplateGalleryPath = "c:\inetpub\wwwroot\templates"