Saturday, April 02, 2011 at 9:08 PM.
radio2Suite.postToJson
on postToJson (adrpost) { <<Changes <<1/8/11; 12:40:48 PM by DW <<Created. local (t = adrpost^); t.idPost = number (nameof (adrpost^)); t.when = date.netstandardstring (t.when); <<scratchpad.t = t bundle { //delete stats table if defined (t.stats) { delete (@t.stats)}}; local (s = "", adr, name, value); for adr in @t { name = json.encode (nameof (adr^)); value = json.encode (string (adr^)); s = s + "\"" + name + "\": \"" + value + "\","}; if sizeof (s) > 0 { s = string.delete (s, sizeof (s), 1)}; s = "{" + s + "}"; return (s)}; bundle { //test code wp.newtextobject (postToJson (@config.radio2.users.dave.feeds.["linkblog.xml"].calendar.["2011"].["01"].["08"].["00012"]), @scratchpad.wtex)}
This listing is for code that runs in the OPML Editor environment. I created these listings because I wanted the search engines to index it, so that when I want to look up something in my codebase I don't have to use the much slower search functionality in my object database. Dave Winer.