Markup for Custom Module
Hi,
I have a separate built module, where you can upload files.
I have built a custom Template, so I read from the document with this:
<
sf:AssetsField
runat
=
"server"
DataFieldName
=
"Document"
/>
<
a
target
=
"_blank"
href
=
"/docs/default-document-library/test.pdf?sfvrsn=0"
class
=
"sfpdf"
id
=
"ctl15_ctl00_ctl00_dynamicContentListView_ctrl1_ctl01_ctl00_ctl00_documentLink_ctl00_ctl00_documentLink"
>test</
a
>
<%@ Control Language="C#" %>
<%@ Register TagPrefix="sitefinity" Namespace="Telerik.Sitefinity.Web.UI" Assembly="Telerik.Sitefinity" %>
<
telerik:radlistview
id
=
"dynamicContentListView"
runat
=
"server"
>
<
ItemTemplate
>
<
asp:Literal
ID
=
"Literal1"
Text='<%# Eval("Description") %>' runat="server" />
<
sitefinity:AssetsField
runat
=
"server"
DataFieldName
=
"Document"
/>
<
sitefinity:AssetsField
runat
=
"server"
DataFieldName
=
"Image"
/>
</
ItemTemplate
>
</
telerik:radlistview
>
<
sitefinity:Pager
id
=
"pager"
runat
=
"server"
>
</
sitefinity:Pager
>
Hi Markus,
What you see in the template is the AssestsField read mode. If you want to change how it works, you will have to inherit from the AssetsField and change its conditional template for read mode, and then when you register the field in your module, you will have to use the inheriting field control. However, you should be careful not to break any of the bindings.
All the best,