ASP.NET Core server

Prev Next
Professional
Business
Enterprise






Hosting a knowledge base in a subfolder offers a seamless way to integrate documentation into your existing website structure. For example, setting up a subfolder path like /help allows users to access your knowledge base directly within your domain, such as example.document360.io/help.

To get started, ensure you replace the example domain in the configurations with your own Document360 provided domain or your custom domain.


Setting up a sub folder path

  1. Install the ASP.Net Core package.

  2. In the Standard.cs file, configure the method as follows:

public void Configure(IApplicationBuilder app, IHostingEnvironment env)
        {
            /// ...
            app.MapWhen(ctx => ctx.Request.Path.StartsWithSegments("/docs"),
                builder => builder.RunProxy(new ProxyOptions() {
                    Scheme = "https",
                    Host="example.document360.io"
            }));
            
           /// ...

NOTE

If you are on KB Site 2.0, and wish to host your Knowledge base as a subfolder, you have to define the Subfolder path as well as the Site API path.


What happens next?

Once you have successfully configured the web server, your knowledge base site is now live on your custom subfolder/subdirectory. However, the existing URL for your project will serve the requests.

For example, example.document360.io and example.com/docs (if /docs is your folder path) will point to the knowledge base site.

This will cause duplicate content in Search engines (Google, Bing, etc.). For this, you will need to enable a URL redirect. Enabling a URL redirect prevents search engines like Google or Bing from indexing duplicate content, which can negatively impact your site's search rankings.

NOTE

To enable the redirect from example.document360.io to example.com/docs, please contact us at support@document360.com.