Re: returning JSONObject always displays the js-code
Em Tue, 22 Sep 2009 10:28:09 -0300, Lionell_Hutz escreveu: Hi there. Hi! I'm using some links and a zone component. the EventHandler looks like this (only some playing around and learning): and I'm alwasy getting an zone-update which shows me the json-onject-literal and not the wished alertbox with 'hi'. What's wrong there? The use of JSON with Zones. :) JSONObject is meant to be used when you write your own JavaScript to request something in your page, component or mixin class, When using Zones, you shouldn't return JSONObjets, as they expect a Block or a component. -- Thiago H. de Paula Figueiredo Independent Java consultant, developer, and instructor http://www.arsmachina.com.br/thiago - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
returning JSONObject always displays the js-code
Hi there. I'm using some links and a zone component. the EventHandler looks like this (only some playing around and learning): public Object onLeague(Object[] in) { ... JSONObject json = new JSONObject(); json.put("content",""); json.put("script", "alert('hi');"); return json; } and I'm alwasy getting an zone-update which shows me the json-onject-literal and not the wished alertbox with 'hi'. What's wrong there? -- View this message in context: http://www.nabble.com/returning-JSONObject-always-displays-the-js-code-tp25530724p25530724.html Sent from the Tapestry - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org