Re: [xwiki-users] blog rss headers enumeration

2008-09-03 Thread Martin Molhanec


OK, I have found a resolution. I put $xwiki.flushCache() at the start of my
code and all is right.
Martin


Martin Molhanec wrote:
 
 Hello, I have written the following testing code:
 Purpose is to enumarate the headers in my blog, I want to create an XWiki
 panel which will show the headers from my blog.
 
 #set($myblogsite=http://andrea4.feld.cvut.cz:8080/xwiki/bin/view/Main/BlogRss?xpage=rdf;)
 #set($myfeed=$xwiki.feed.getFeed($myblogsite))
 Title of blog: ${myfeed.getTitle()}\\
 Link to blog site: ${myfeed.getLink()}\\
 Link to blog: $myblogsite
 #set($myfeedEntries=$myfeed.getEntries())
 #set($_i=0)
 #foreach ($item in $myfeedEntries)
   #set($_i=$_i+1)
 Item: $_i)\\
 Title: $item.getTitle()\\
 Contents:($item.getDescription().value)\\
 #end
 \\Sum: $_i message(s)\\
 
 {rss:feed=$myblogsite|full=true}
 
 The testing page is here:
 http://andrea4.feld.cvut.cz:8080/xwiki/bin/view/Sandbox/pokus4
 and here
 http://andrea4.feld.cvut.cz:8080/xwiki/bin/view/Sandbox/pokus3
 
 Interestingly my own blog has 3 messages and I can enumerate only one. 
 But, test with the blog from xwiki.com is right.
 Any help?
 
 

-- 
View this message in context: 
http://n2.nabble.com/blog-rss-headers-enumeration-tp794045p835955.html
Sent from the XWiki- Users mailing list archive at Nabble.com.

___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] blog rss headers enumeration

2008-09-02 Thread Martin Molhanec

OK, no one answered me yet :-( But I discover a matter.
When I restarted Tomcat, I can see all messages at once. Probably a matter
of caching?
How it is possible to disable a cache for blog before I execute a command
getFeed()?
Yes, it is a very strange behavior  :-( Help me!
So no one have made a panel with blog/rss headers yet?
-- 
View this message in context: 
http://n2.nabble.com/blog-rss-headers-enumeration-tp794045p833867.html
Sent from the XWiki- Users mailing list archive at Nabble.com.

___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] blog rss headers enumeration

2008-09-01 Thread Martin Molhanec

Yes, very strange. Something more about my problem. I have now this code:

#set($feed=$xwiki.feed.getFeed(http://andrea4.feld.cvut.cz:8080/xwiki/bin/view/Main/BlogRss?xpage=rdf;))
Počet: $feed.entries.size()\\
\\
#foreach($entryIndex in [0..9])
 #if($entryIndex$feed.entries.size())
  #set($entry=$!feed.entries.get($entryIndex))
 
#set($fullTitle=$entry.title.replaceAll(',\\\').replaceAll('','\\\'))
  #if ($fullTitle.length()$maxTitleLen)
   #set($myDisplayTitle=$fullTitle.substring(0,$maxTitleLen)...)
  #else
   #set($myDisplayTitle=$entry.title)
  #end
Date:  $entry.publishedDate\\
FullTitle:  $fullTitle\\
Link:  $entry.link\\
Title:  $myDisplayTitle\\
 #else
  div class=feedItem /div
 #end
\\
#end

{rss:feed=http://andrea4.feld.cvut.cz:8080/xwiki/bin/view/Main/BlogRss?xpage=rdf|full=true}

Here: http://andrea4.feld.cvut.cz:8080/xwiki/bin/view/Sandbox/pokus6
the result is only one item and it is wrong
but here: http://xena4.feld.cvut.cz:8080/xwiki/bin/view/Sandbox/pokus
the result is all three items, it is right.
The code is same, only differ the location of the code. 
Any help?
Thanx.






Martin Molhanec wrote:
 
 Hello, I have written the following testing code:
 Purpose is to enumarate the headers in my blog, I want to create an XWiki
 panel which will show the headers from my blog.
 
 #set($myblogsite=http://andrea4.feld.cvut.cz:8080/xwiki/bin/view/Main/BlogRss?xpage=rdf;)
 #set($myfeed=$xwiki.feed.getFeed($myblogsite))
 Title of blog: ${myfeed.getTitle()}\\
 Link to blog site: ${myfeed.getLink()}\\
 Link to blog: $myblogsite
 #set($myfeedEntries=$myfeed.getEntries())
 #set($_i=0)
 #foreach ($item in $myfeedEntries)
   #set($_i=$_i+1)
 Item: $_i)\\
 Title: $item.getTitle()\\
 Contents:($item.getDescription().value)\\
 #end
 \\Sum: $_i message(s)\\
 
 {rss:feed=$myblogsite|full=true}
 
 The testing page is here:
 http://andrea4.feld.cvut.cz:8080/xwiki/bin/view/Sandbox/pokus4
 and here
 http://andrea4.feld.cvut.cz:8080/xwiki/bin/view/Sandbox/pokus3
 
 Interestingly my own blog has 3 messages and I can enumerate only one. 
 But, test with the blog from xwiki.com is right.
 Any help?
 
 

-- 
View this message in context: 
http://n2.nabble.com/blog-rss-headers-enumeration-tp794045p796968.html
Sent from the XWiki- Users mailing list archive at Nabble.com.

___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users