title: How to access a field of type "Link to Page" in Liferay Application Display Templates (ADT)?
body: <p>I have a web content structure (<a href="https://dev.liferay.com/discover/portal/-/knowledge_base/6-2/advanced-content-with-structures-and-templates" rel="nofollow">WCM</a>) with a Field of type "<em>Link to page</em>" (<code>ddm-link-to-page</code>). Then I created an asset publisher template (<a href="https://dev.liferay.com/discover/portal/-/knowledge_base/6-2/using-application-display-templates" rel="nofollow">ADT</a>) to display the link for pages of the web content.</p>
  
  <pre><code>&lt;#assign journalArticle = assetRenderer.getArticle() /&gt;
  &lt;#assign document = saxReaderUtil.read(journalArticle.getContentByLocale(locale.toString())) /&gt;
  &lt;#assign URLnode = document.selectSingleNode("/root/dynamic-element[@name='Link_To_Page']/dynamic-content") /&gt;
  &lt;#assign getURL = URLnode.getText() /&gt;
  
  &lt;a href="${getURL}"&gt;Go to page&lt;/a&gt;
  </code></pre>
  
  <p>The problem is that the value displayed is a reference to the element and not the value of the link (it shows <code>/348@public@9246542</code>) so
  <strong><code>URLnode.getText()</code></strong> is not working.</p>
  
  <p>All other field works.</p>
  
  <p><sup>ps. I also tried with <code>URLnode.getStringValue()</code></sup></p>