How to still get the Key-Value pair even though Value in the Hash is null
ven12344 <[email protected]> Mon, 15 Sep 2014 15:08:49 -0700 (PDT)
| Newsgroups | gmane.comp.web.freemarker.user |
|---|---|
| Message-ID | <[email protected]> |
Hi, I am getting the nodes from an xml file, like this <#local titles = doc[XPATH] > lets say for one element, this xpath does not exist. What I need to do is that I need to replace the "null" with "empty". But I am not even getting this key-value pair in the local variable "titles", like Java Hash concept, if the value of the element in Hash is null then entire element becomes null, right. I am looking solution in XPath, to check if the xpath exists then get the value of it otherwise put the value as "empty". But could not able to get the solution. If anybody knows how to do it in Freemarker or XPath, I will appreciate the help. Thanks. -- View this message in context: http://freemarker.624813.n4.nabble.com/How-to-still-get-the-Key-Value-pair-even-though-Value-in-the-Hash-is-null-tp4655272.html Sent from the freemarker-user mailing list archive at Nabble.com. ------------------------------------------------------------------------------ Want excitement? Manually upgrade your production database. When you want reliability, choose Perforce Perforce version control. Predictably reliable. http://pubads.g.doubleclick.net/gampad/clk?id=157508191&iu=/4140/ostg.clktrk