On Wed, 28 Dec 2011 14:40:12 -0200, Javix <s.camb...@gmail.com> wrote:

In javascript, I just replaced arguments by jsonObject:

function load(jsonObject){
...
//acces to the variable in JSON
errorText.text(jsonObject.m2)
}

Why in case of JSON it DOES NOT WORK ?

From the addInit() JavaDoc, specifically the first parameter:

functionName the name of the function (on the client-side Tapestry.Initializer object) to invoke.

addInit() just invokes functions that are part of the Tapestry.Initializer object. Try this instead:

Tapestry.Initializer.load = function(jsonObject){
 ...
 //acces to the variable in JSON
 errorText.text(jsonObject.m2)
}

--
Thiago H. de Paula Figueiredo
Independent Java, Apache Tapestry 5 and Hibernate consultant, developer, and instructor
Owner, Ars Machina Tecnologia da Informação Ltda.
http://www.arsmachina.com.br

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org

Reply via email to