java.util.Calendar calendar = java.util.GregorianCalendar.getInstance()
month = calendar.get(calendar.MONTH)+1
year = calendar.get(calendar.YEAR)
theMonth = "${month}"
if (month < 10)
theMonth = "0${month}"diaryLink = "${year}${theMonth}"
//sql = "select doc.web,doc.fullName,docstats.pageViews from XWikiDocument as doc, DocumentStats as docstats where docstats.name=doc.fullName and doc.name='Blog' and docstats.action='view' and docstats.period='$diaryLink' group by doc.fullName order by docstats.pageViews desc"sql = "select distinct doc.web,doc.fullName from XWikiDocument as doc where doc.name='Blog' order by doc.fullName"
for (item in xwiki.xWiki.store.search(sql,50,0,context.context)) {//out.println(""+item[0+">"+item1+"] - "+item2+" hits")
out.println(""+item[0+">"+item1+"]")
}%>