Check out the "Ajax" examples; they should illustrate a method for doing what you want (i.e. updating some page content based on the result of an ajax call, if i understand you correctly).
The AutocompletField uses the Prototype javascript frawework to simplify the coding of more complicated javascript. If you're building your own control, you can skip the prototype dependencies (using another framework such as jQuery or foregoing altogether and writing 'straight' javascript). Also, If you want some extra tools in writing Ajax within click, check out Bob's "ajax4click" http://code.google.com/a/apache-extras.org/p/ajax4click/ (which uses jQuery currently) and/or take a look at some example code I've written up for manipulating controls with ajax (http://www.hoolehan.com/computer/apache_click_dom_event_actionresults.html) 2011/8/11 Emerson Castañeda <[email protected]>: > Hi everyone > > I'v been using Click for some time, right now I'm coding a aplication that > allows to create user accounts, all validations in the html form are working > right after submiting it, even a simple captcha implementation that I have > included. > > I'd like to check the availibility of a new username before submit the form, > I think the sample of AutoCompleteTextField control that is included in > Apache Click Extras Project should be a good guide to try implement a new > control that does that validation and implements some graphic effect on the > presentation layer. Looking the code and around all dependeces of > AutoCompleteTextField (/click/control.js, /click/prototype/prototype.js, > /click/prototype/effects.js, /click/prototype/controls.js) it results too > complex to me. > > My question is: some ne have a idea about how i can implement this kind of > funcionality in a easier way without altering the philosopy of Click > Framework? > > Thanks in advance for your help. > > EmeCas >
