-- Csányi András <[EMAIL PROTECTED]> wrote
(on Monday, 17 March 2008, 10:59 PM +0100):
> On Mon, Mar 17, 2008 at 08:31:56AM -0700, Andi Gutmans wrote:
> >    Here's an example with Dojo:
> > 
> >    
> > http://framework.zend.com/manual/en/zend.controller.actionhelpers.html#zend.controller.actionhelpers.autocomplete.dojo
> > 
> >     
> > 
> >    Not sure if that's what you meant or you're looking for something 
> > broader.
> > 
> >    Andi
> 
> Hi Andi!
> 
> I read in the documentation i can use Zend Framework with sciptacoulous and 
> dojo. I can use
> the Framework only with these AJAX tools?
> 
> I use jQuery and the dojo and scriptacoulous are strange for me.

You can use *any* JS library you want with ZF; ZF acts serverside and is
basically agnostic when it comes to the queries sent to it. 

That said, the AutoComplete action helper has two concrete extensions,
one for interacting with Dojo and another for interacting with
Scriptaculous. This is because each JS library expects something
different for its autocompletion widgets. Dojo expects a JSON struct of
the form:

    array(
        'identifier' => <name of key representing value in items arrays>,
        'items'      => array(
            array(<assoc array with keys, one of which must be the identifier),
            ...
        )
    )

Scriptaculous, on the other hand, expects an HTML unordered list, which
you then style using some standard CSS. Thus, the two concrete versions
return the data in the format each understands.

For other AJAX queries, you're limited simply by what you can program in
your actions. :-)

-- 
Matthew Weier O'Phinney
PHP Developer            | [EMAIL PROTECTED]
Zend - The PHP Company   | http://www.zend.com/

Reply via email to