Topic: GetFormValues pattern matching

Although you can use a prefix, would it be possible to add pattern matching in the future, I need to be able to return groups of fields and a single prefix won't do this.

for instance take these field names:
  __A__Address1,  __A__Address2,  __B__Setting1,__B__Setting2, __AB__Something1, __AB__Something2, __B__Anotherfield

If I had pattern matching I could retrieve __*A*__* to get everything in group A or __*B*__* to retrieve all of group B etc.

Or I could retrieve just the data pertaining to a single ID.

Not sure if this is the best description but it kind of makes sense to me!!!

Re: GetFormValues pattern matching

You could group them in seperate <form> tags?  Or pass them in manually into the function, and not use the getFormValues call?

Re: GetFormValues pattern matching

You could also use more than one call to getFormValues, passing a different prefix to each call; then your request handler can merge the arrays.  It would also be possible to merge the results from getFormValues, if you were using the xajax 0.5 beta 3 (currently in SVN only) as getFormValues returns a javascript array.  In previous versions, getFormValues returns a string which is converted to an array on the server side.

Hope that helps.

// Joe

xajax Developer
Connect to me on LinkedIn:
http://www.linkedin.com/in/calledtoconstruct