Well thats what I looked at first, and then I tried this:
<script type="text/_javascript_">
    dojo.require("tapestry.form");
    tapestry.form.registerForm("ajaxform",true,"");
</script>

but still got this:
The _javascript_ console Error: tapestry is not defined
Source File: 
http://localhost:8081/IRM2/app?page=PortfolioAllocations&service=page
Line: 190... tapestry.form.submitAsync(dojo.byId("ajaxform"), args);

It complains that the Object Tapestry is undefined which is strange because it's meant to be included in every page with the @shell component.

"By default, the Shell component will include the core dojo _javascript_ object dojo.js, as well as the new core Tapestry _javascript_ object - core.js."

Is it?? and if so how can I submit the form asynchronously using _javascript_.

andyhot wrote:
Looks like http://tapestry.apache.org/tapestry4.1/_javascript_/index.html
hasn't been updated lately...

Take a look at the source, it might help...
https://svn.apache.org/repos/asf/tapestry/tapestry4/trunk/tapestry-framework/src/js/tapestry/form.js

	 /* Parameters:
	 * 
	 *	id		-	The form(form id) to register.
	 *  async	-	Boolean, if true causes form submission to be asynchronous.
	 *  json	-	Boolean, if true causes form submission to be asyncrhronous with an 
	 * 				expected JSON response.
	 */
	registerForm:function(id, async, json){ ... }





Peter Stavrinides wrote:
  
Yes, I did know that tacos is not supported in 4.1, sorry that line is
meant to be commented out... I only need to change the way it submits.
tapestry.form.submitAsync(dojo.byId("ajaxform"), args));
instead of:
tacos.formSubmit(args);

but it won't work?
  

andyhot wrote:
    
1st tacos is currently completely unsupported in 4.1.x
2nd, did you mean to write

tapestry.form.submitAsync(dojo.byId("ajaxform"), args)

instead of

tapestry.form.submitAsync(dojo.byId("ajaxform", args)



Peter Stavrinides wrote:
  
      
Hi,

I am currently upgrading a component from Tapestry 4.02 to Tapestry 4.1 
The problem is that once I upgrade, my submit no longer works?? 
unfortunately I have limited Dojo skills, but this should be pretty 
simple to solve...here is the code:


Tapestry 4.0.2 with tacos
var args = { url: "", processScripts: "true", updateComponents: 
"forRefresh2", effects: {}, content: {dojoRequest: "true", 
processScripts: "true" },
                 formId: "ajaxform", backLink: "", forwardLink: "", 
statusElement: ""};           
                 tacos.formSubmit(args); // actually submit
                 timeout = setTimeout("reloadForm()",3000);     //set 
the delayed refresh
       

In Tapestry 4.1 I tried
dojo.require("tapestry.form");
tapestry.form.registerForm(dojo.byId("ajaxform"));

var args = { url: "", processScripts: "true", updateComponents: 
"forRefresh2", effects: {}, content: {dojoRequest: "true", 
processScripts: "true" },
               formId: "ajaxform", backLink: "", forwardLink: "", 
statusElement: ""};           
              tacos.formSubmit(args); // actually submit
tapestry.form.submitAsync(dojo.byId("ajaxform", args)
timeout = setTimeout("reloadForm()",3000); //set delayed refresh

The _javascript_ console Error: tapestry is not defined
Source File: 
http://localhost:8081/IRM2/app?page=PortfolioAllocations&service=page
Line: 190 (tapestry.form.submitAsync(dojo.byId("ajaxform", args))

Kind regards,
Peter


-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Tacos-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tacos-devel

  
    
        
  
      
-- 
Peter Stavrinides
Albourne Partners (Cyprus) Ltd
Tel: +357 22 750652

If you are not an intended recipient of this e-mail, please notify the sender, delete it and do not read, act upon, print, disclose, copy, retain or redistribute it. Please visit http://www.albourne.com/email.html for important additional terms relating to this e-mail. 
------------------------------------------------------------------------

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
------------------------------------------------------------------------

_______________________________________________
Tacos-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tacos-devel
  
    


  

-- 
Peter Stavrinides
Albourne Partners (Cyprus) Ltd
Tel: +357 22 750652

If you are not an intended recipient of this e-mail, please notify the sender, delete it and do not read, act upon, print, disclose, copy, retain or redistribute it. Please visit http://www.albourne.com/email.html for important additional terms relating to this e-mail. 
-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Tacos-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tacos-devel

Reply via email to