News
An error occurred while processing the template.
Expression docRoot.selectSingleNode("//dynamic-element[@name='Main_image']/dynamic-content") is undefined on line 24, column 45 in 10154#10194#200227.
1<#assign layoutLocalService = serviceLocator.findService("com.liferay.portal.service.LayoutLocalService")/>
2
3<#assign isFirst=true/>
4<#if entries?has_content>
5
6 <#list entries as curEntry>
7
8 <#assign docRoot= saxReaderUtil.read(curEntry.getAssetRenderer().getArticle().getContentByLocale(locale))/>
9
10 <#assign viewURL = themeDisplay.getURLHome() + layoutLocalService.getFriendlyURLLayout(10181,false,"/news").getFriendlyURL(locale) + "/content/read/${curEntry.getAssetRenderer().getUrlTitle()}" />
11
12 <#assign Date_DateObj = curEntry.getAssetRenderer().getArticle().getDisplayDate()>
13
14 <#assign newsContent = htmlUtil.extractText(docRoot.selectSingleNode("//dynamic-element[@name='Content']/dynamic-content").getText())/>
15
16 <#assign aDateTime = .now>
17<#assign aDate = aDateTime?date>
18
19 <#if Date_DateObj?date <= aDate?date>
20
21
22 <div class="row-fluid" style="margin-bottom:50px;">
23 <div class="span5">
24 <img src="${docRoot.selectSingleNode("//dynamic-element[@name='Main_image']/dynamic-content").getText()}" width="390" height="202" style="display:block;margin:auto"/>
25 </div>
26
27 <div class="span7" style="margin-left:0;">
28
29
30
31
32 <p class="compact">
33 <i class="icon-calendar" style="margin-right:10px;"></i>
34 ${dateUtil.getDate(Date_DateObj, "dd MMM yyyy", locale)}
35
36 <!--<i class="icon-tags" style="margin-left:10px;margin-right:10px;"></i>-->
37 </p>
38
39 <h3 class="blu" style="font-weight:normal;"><a href="${viewURL}" class="blu">
40 ${curEntry.getAssetRenderer().getArticle().getTitle(locale)}
41 </a></h3>
42
43 <div>
44 <#if (newsContent?length > 500)>
45 ${newsContent?substring(0,499)}...
46 <#else>
47 ${newsContent}
48 </#if>
49
50 </div>
51
52 <a href="${viewURL}" class="green">${languageUtil.get(locale,"continue")} ></a>
53
54
55
56
57 </div>
58 </div>
59
60 <#if (isFirst) >
61 <div class="row-fluid" style="margin-bottom:50px;">
62 <iframe frameborder="0" class="responsiveTrovaContentDiv" src="https://www.plasticfinder.it/press/adv/newsletter" width="800" height="150" scrolling="no" style="border:0;display:block;margin:auto;"></iframe>
63 <#assign isFirst=false/>
64 </div>
65
66 </#if>
67 <#else>
68
69 </#if>
70 </#list>
71
72</#if>