Our Environment : SDL Tridion 2013 SP1 I'm new to Tridion. We are trying to generate sitemap.xml for the site using Tridion. We wrote TBB which generated the sitemap in XML format and its being generated correctly. Now how would I call this from my .NET application and render it to the View and display the generated XML format on the page. I tried calling the hard coded file name (sitemap.xml) in controller and getting the xml data in string format correctly, now I need to pass this string from controller to View to display the data in XML format. Please suggest:

  1. the approach is correct to generate sitemap.xml and
  2. how to pass the XML of string format to View, so that it display in xml format
  • You mentioned views and controllers, are you using DD4T or DXA, or is it a custom MVC app?
    – Atila Sos
    Jan 12, 2020 at 18:17
  • .Net DXA 1.7 application
    – Thakur
    Jan 13, 2020 at 0:40
  • DXA provides sitemap.xml OOTB. Why are you trying to generate it yourself? Jan 16, 2020 at 14:53

1 Answer 1


Since, you are using DXA, I will say the approach of generating the sitemap might not makes sense (unless there are other fine prints which we are not aware about).

The correct approach could be similar to the one mentioned here: Generate Sitemap XML File using default functions of DXA 1.5/1.7 in Web 8/8.5

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.