- Powered by Domino 8.5.2 Domino Accelerator Pack
- Accelerate your web applications
Lotus Triple Search DominoExperts + Blogs + R8 forum -> Script vault -> JavaScript

 JSON support in Domino 7.02

Tomas NielsenPost date: 2007-03-06 20:54

One of my colleagues tipped me of the other day of the new, undocumented, feature added to readviewentries. There is nothing in the help files but there is some buzz about it on the web.

The syntax is to open a view using:


See an example of the news view for this site in JSON format below:

I guess this can be useful, I will try to think of an excuse to use it.

Jonas IsraelssonPost date: 2007-03-11 14:07

You are allowed to mention my name. ;)

This will be a huge leap forward in the simplicity of creating Ajax-based solutions to existing Domino solutions without having to create the JSON transport layer yourself for every new solution.

Fredrik StöckelPost date: 2007-03-27 10:34

This is very cool! But I wonder why they decided to keep the "@" prefix in the variables? (it's still there in Beta 2).

It makes it a bit limited ragarding how to access the members in the json-object, you can't use the dot notation due to thís... (eg obj.@toplevelentries) ... and have to use the obj["@toplevelentries"] instead... I hope this will change in the final version.

Tomas NielsenPost date: 2007-03-27 21:41

Yes, you have got a point there Fredrik. My guess is though that it will remain as is since people has already started to use it.

Fredrik StöckelPost date: 2007-03-28 15:03

I really hope it will change. I have played a bit with the JSONT template engine (similar to the one found in Ext) and I get wierd results/errors in IE due to the prefix.  The IE jscript engine uses @variables as conditional compilation variables:


Tomas NielsenPost date: 2007-03-28 19:28

Have you reported it in the Beta forum?

I have submitted a little annoyance about the favicon.ico file being overwritten but this seem more prioritized.

Fredrik StöckelPost date: 2007-03-29 10:27

Yepp, It's reported.
I hope they decide to fix it, it will be much harder to change the format after the gold release.

Tomas NielsenPost date: 2007-04-27 15:13

Another one of the releses that came during Lotusphere was the field: $$HTMLFrontMatter

Whatever you put in that field will appear before the <html> tag.

Niklas WallerPost date: 2007-05-10 21:42

Viktor Krantz, the famous swede from Snapps who together with Rob Novak holds the popular seminar 'The Great Code Giveaway' at Lotusphere, has posted a topic about JSON on his blog called 'Faster AJAX with Domino'. The point is that he has compared an XML Get query with a JSON Get Query using Firebug in Firefox and come to the result that the JSON Get query is faster with an average of 275%.

He uses 'ReadViewEntries' and 'ReadViewEntriesoutputformat=json' to get the XML and JSON.

/ Niklas

Tomas NielsenPost date: 2007-05-11 21:47

Interesting reading, Niklas! (And welcome here!)

I attended the great code give away. It was impressing! (Were you there?)

I will probably use JSON more than I will use ReadViewEntries anyway. But it is nice to hear it is fast too.

Niklas WallerPost date: 2007-05-12 14:56

Thank's! I would have loved to be at Lotusphere this year. Unfortunately I wasn't, but I attended Lotusphere and the Great Code Giveaway last year (2006) and it was very good.

This year it was actually the most top-rated session at Lotusphere, take a look here.

I agree, JSON seems like the best choice.

Niklas WallerPost date: 2007-05-23 07:42

Here's an update to Viktor Krantz's post about Faster AJAX with Domino and JSON in where he includes the sample database and instructions.
// Niklas

RSS feed
Subscribe to Forum

Share this page

Top posters
Tomas Nielsen212
Joacim Boive27
Fredrik Stöckel27
Niklas Waller13
Kenneth Haggman11
Bryan Kuhn10
Daniel Lehtihet9
Jonas Israelsson8