Fórum
Get URL for DLFileEntry
Tom Vleminckx, modificado 12 Anos atrás.
Get URL for DLFileEntry
Junior Member Postagens: 39 Data de Entrada: 27/06/11 Postagens Recentes
Hello,
Is there an util class or method to generate the URL for a fileentry in de documentlibrary?
Thank you,
Is there an util class or method to generate the URL for a fileentry in de documentlibrary?
Thank you,
Ravi Kumar Gupta, modificado 12 Anos atrás.
RE: Get URL for DLFileEntry
Liferay Legend Postagens: 1302 Data de Entrada: 24/06/09 Postagens Recentes
Check view_file_entry.jsp in tomcat-6.0.29\webapps\ROOT\html\portlet\document_library directory. It has fileUrl variable. See how that is formed.
HTH
HTH
Sagar A Vyas, modificado 12 Anos atrás.
RE: Get URL for DLFileEntry
Liferay Master Postagens: 679 Data de Entrada: 17/04/09 Postagens RecentesTom Vleminckx:
Hello,
Is there an util class or method to generate the URL for a fileentry in de documentlibrary?
Thank you,
Hi Tom,
Just do as below you will get url of particular DLFileEntry
<a href='<%=themeDisplay.getPortalURL()+"/c/document_library/get_file?uuid="+dlFileEntry.getUuid()+"&groupId="+themeDisplay.getScopeGroupId() %>' >
MyFile </a>
Thanks,
Sagar Vyas
Tom Vleminckx, modificado 12 Anos atrás.
RE: Get URL for DLFileEntry
Junior Member Postagens: 39 Data de Entrada: 27/06/11 Postagens Recentes
Allright,
Thank you both for the quick response.
Tom
Thank you both for the quick response.
Tom
Roberto Javier, modificado 12 Anos atrás.
RE: Get URL for DLFileEntry
New Member Postagens: 5 Data de Entrada: 01/03/12 Postagens Recentes
Excellent, thank you very much Sagar ...
Sagar A Vyas, modificado 12 Anos atrás.
RE: Get URL for DLFileEntry
Liferay Master Postagens: 679 Data de Entrada: 17/04/09 Postagens RecentesRoberto Javier:
Excellent, thank you very much Sagar ...
Glad to know it helps you
me liferay, modificado 11 Anos atrás.
RE: Get URL for DLFileEntry
Junior Member Postagens: 25 Data de Entrada: 14/12/11 Postagens Recentes
Is there a way to get it in the ModelLisetener class because in that class we do not have themdisplay object reference.
all I have id dlfileEntry reference.
all I have id dlfileEntry reference.
Sai Sriharsha Kasturi, modificado 9 Anos atrás.
RE: Get URL for DLFileEntry
Junior Member Postagens: 34 Data de Entrada: 21/10/12 Postagens Recentesme liferay:
Is there a way to get it in the ModelLisetener class because in that class we do not have themdisplay object reference.
all I have id dlfileEntry reference.
Try this,
String portalURL = PortalUtil.getPortalURL(company.getVirtualHostname(), PortalUtil.getPortalPort(), false);
String url = portalURL + "/c/document_library/get_file?uuid=" + dlfileEntry.getUuid() + "&groupId=" + dlfileEntry.getGroupId();