Setting up DSS with ASP.NET MVC Views to Render Content


Prerequisites:

To render content on the DSS using ASP.NET MVC views, set up your DSS project to include the necessary views and supporting files. By previewing the content in the Preview tab and publishing your content to the DSS in advance, you can confirm the rendered output aligns with your intended design and presentation. This approach allows you to validate your setup and make adjustments before the content goes live.

To set up the DSS with ASP.NET MVC:
  1. Copy code files from your CMS installation folders to the deployment folders within the DSS folder structure.
    1. Navigate to [Drive]:\[Path-to-CMS]\site\DSS_Preview\views, your views folder within your CMS installation.
    2. Copy your custom views to your DSS installation folder, [Drive]:\[Path-to-DSS]\[DSS-Name]\Views.
      Caution
      Do not copy _ViewStart.cshtml or Web.config. These files are specific to your CMS installation.
    3. If you have any custom controllers, copy them from your CMS installation—[Drive]:\[Path-to-CMS]\[CMS-Name]\site\DSS_Preview\controllers—to your DSS installation folder—[Drive]:\[Path-to-DSS]\[DSS-Name]\Controllers.
    4. If you have any custom models, copy them from your CMS installation—[Drive]:\[Path-to-CMS]\[CMS-Name]\site\DSS_Preview\models—to your DSS installation folder—[Drive]:\[Path-to-DSS]\[DSS-Name]\Models).
    5. If you have images or scripts that are external to the CMS, copy them to the root of the DSS folder structure.
    6. Confirm that your DSS helper and function files, located at [Drive]:\[Path-to-DSS]\[DSS-Name]\App_Code, are up-to-date by comparing them with the corresponding files in [Drive]:\[Path-to-CMS]\site\DSS_Preview\app_code. If the modified date of these DSS files is older than those in the CMS installation, replace the DSS files with the more recently updated CMS installation files.
  2. If you have copied custom controllers from the CMS to the DSS, then you must Clean and Rebuild your DSS project. Dynamic_Site_Server_Instance.csproj, the Visual Studio .NET C# project file, is located in the root folder of the DSS installation. For information about rebuilding Visual Studio projects, see Building and Cleaning Projects and Solutions in Visual Studio.
  3. Configure Replication if it has not already been configured.

Next Steps: After completing the steps above, verify that your staging DSS site displays content correctly by navigating to its URL in a browser.