Skip to content

ASP.NET Web Forms version of an editor for Ignia’s OnTopic CMS. Deprecated in favor of the new ASP.NET Core version.

Notifications You must be signed in to change notification settings

OnTopicCMS/OnTopic-Editor-WebForms

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

84 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

OnTopic Editor for Web Forms

The OnTopic-Editor-WebForms is the legacy implementation of the OnTopic Editor for Microsoft's ASP.NET Web Forms framework.

Important: This project is considered obsolete, and no longer supported by Ignia. It is provided exclusively for reference. Existing implementations and new customers should upgrade to OnTopic-Editor-AspNetCore, which is built on Microsoft's ASP.NET Core 3.1.

Installation

Dependencies

Unlike more recent versions of the editor, the Web Forms version does not incorporate package management for downloading client-side dependencies, nor is it itself distributed as a package. To install the application, the following must be done:

Scripts

Client-side scripts must be downloaded and placed in the appropriate /OnTopic.Editor.Web/Common/Scripts/Vendor folders:

Libraries

There are a few dependencies that were previously distributed as a loose collection of proprietary scripts that need to be placed in the /OnTopic.Editor.Web.Host/Common/Global folder. These can be provided by Ignia upon request.

  • /Common/Global/Client.Scripts/FormatPhone.js
  • /Common/Global/Client.Scripts/ClientValidation.js
  • /Common/Global/Controls/ClientValidation.ascx
  • /Common/Global/CS.Functions/AddAttributeToFields.aspx

Host Site

Once all of the dependencies are procured, the contents of the OnTopic.Editor.Web folder should be copied to the appropriate location in your host site. By convention, Ignia has traditionally placed this in the /!Admin/Topics directory, but the location is not fixed.

Configuration

For a configuration example, see the OnTopic.Editor.Web.Host project. It includes the absolute bare minimum configuration required to host the editor. This includes:

  • web.config
    • connectionString named OnTopic
    • pageBaseType set to TopicPage
    • Reference to the OnTopic namespaces
    • Configuration of the C# compiler
    • Inclusion of the .NET Standard 2.0 assembly
  • packages.config
    • Declaring OnTopic dependencies, such as OnTopic, OnTopic.Web, OnTopic.Data.Sql, &c.
  • global.asax.cs
    • Override TopicFactory.TypeLookupService with WebFormsTopicLookupService
    • Configure the TopicRepository.DataProvider
    • Ignore routes going to {resource}.axd/{*pathInfo}

Visual Studio

If you are trying to get the OnTopic.Editor.Web.Host site working in Visual Studio, you'll want to setup a virtual directory from OnTopic.Editor.Web.Host to Ontopic.Editor.Web. This can be done in your local copy of .vs/config/applicationHost.config by adding a <virtualDirectory /> element to the corresponding <site />. For example:

<configuration>
  <system.applicationHost>
    <sites>
      <site name="OnTopic.Editor.Web.Host" id="3">
        <application path="/" applicationPool="Clr4IntegratedAppPool">
          <virtualDirectory path="/" physicalPath="C:\Code\OnTopic-Editor-WebForms\OnTopic.Editor.Web.Host" />
          <virtualDirectory path="/!Admin/Topics" physicalPath="C:\Code\OnTopic-Editor-WebForms\OnTopic.Editor.Web" />
        </application>
        <bindings>
          <binding protocol="http" bindingInformation="*:63857:localhost" />
        </bindings>
      </site>
    </sites>
  </system.applicationHost>
</configuration>

Note: The path does not need to be setup to /!Admin/Topics, though that's the convention Ignia has traditionally used for this version of the editor.