Page 1 of 1

nVelocity Question

Posted: Thu Jul 31, 2008 1:54 pm
by trozzi
I want to conditionally use ConLib user controls in a scriptlet based on categoryId

Can I retrieve the category Id via nVelocity scriptlet language?

Thanks
Thomas

Re: nVelocity Question

Posted: Thu Jul 31, 2008 2:09 pm
by jmestep
Yes. I have done that in Shopping Bar scriplet to show news feeds based on different search terms, using Mazhar's news feed conlib:

Code: Select all

#if ($Category.CategoryId == 7)
[[Conlib:Custom/RssReader FeedUrl=" http://news.search.yahoo.com/news/rss?p=keyword1+keyword2 &ei=UTF-8&fl=0&x=wrt#" Name="" MaximumResults="7" ShowUpdateDate="true" ShowDescription="true" ShowItemImage="false" ShowPubDate="true" ShowChannelTitle="false" ShowChannelDescription="false" ShowChannelSeperator="true" ShowChannelImage="false"]]
#end