[opencms-dev] get the link to the right page from the CmsResult

Borja Marcos Suarez borja.suarez at fundacionctic.org
Tue Jun 14 13:04:34 CEST 2005


Hi all,

 

In a jsp for searching contents I have:

 

                                   <dl>

                                               <dt><%= entry.getScore()
%>% - <a href="<%= action.link (entry.getPath()) %>"><%=
entry.getTitle() %></a></dt>

                                               <dd>

 
<strong>Modificado el:</strong> (<%= entry.getDateLastModified() %>)

                                                           <br />

 
<strong>Extracto:</strong><%= entry.getExcerpt() %><br />

                                               </dd>

                                    </dl>

-----------------

action is a CmsJspActionElement object.

entry is a CmsSearchResult object

 

 

This doesn't work because the getPath method returns a string beginning
with /sites/default

 

Can anyone tell me how to get the right link from the CmsResult?

 

I'm sure that it is very easy but my mind is not working fine today ;)

 

Thanks in advance,

 

Borja

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://webmail.opencms.org/pipermail/opencms-dev/attachments/20050614/3a3923a3/attachment.htm>


More information about the opencms-dev mailing list