If anybody has some context of component link resolving for richtextbox in DXA with .net

The RTF field has the following HTML inside <a title="xyz" href="tcm:125-12345">linktext</a>

I am trying to resolve it using @Html.DxaRichText(field)

but it shows the plain text on the page. It does not show any link. I do not see any anchor tag in rendered HTML. Is there any method available in DXA to resolve the link?

1 Answer 1


If all is well, Component Links within rich text are stored in CM as XLinks. That is: as an xlink:href attribute (instead of just href, which is normally used in XHTML).

The DXA model mapping code automatically detects such XLinks and will resolve them to a Page URL (using CD Linking APIs), turning the XLink into a regular HTML hyperlink. See: https://github.com/sdl/dxa-web-application-dotnet/blob/master/Sdl.Web.Tridion/Mapping/DefaultRichTextProcessor.cs

  • The github link is broken. Oct 16, 2019 at 13:47

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.