| Beispiele |
Reading an item, in normal and short form:
return this.item("body");
return this.body
Reading a metadata field, in this example the database key of the database in context:
return this.meta("db", "dbkey");
Fetching a different TML context object. The object fetched is again a TML context object offering the same functions but having a different content document in context:
var rootContext = this.context("root");
Since WGA 3.2 the "this" object is implicit and needs not to be specified. The given examples could be written like this:
return item("body");
return body;
return meta("db", "dbkey");
var rootContext = context("root"); |