Пример #1
0
 /**
  */
 public function generate(Horde_Core_Ajax_Imple_AutoCompleter $ac)
 {
     $dom_id = $ac->getDomId();
     if (!isset($this->params['trigger'])) {
         $this->params['trigger'] = $dom_id;
     }
     if (!isset($this->params['uri'])) {
         $this->params['uri'] = strval($ac->getImpleUrl()->setRaw(true));
     }
     return 'new PrettyAutocompleter(' . Horde_Serialize::serialize($dom_id, Horde_Serialize::JSON) . ',' . '{' . implode(',', $this->_getOpts($ac)) . '})';
 }
Пример #2
0
 /**
  */
 public function generate(Horde_Core_Ajax_Imple_AutoCompleter $ac)
 {
     $dom_id = $ac->getDomId();
     if (!isset($this->params['trigger'])) {
         $this->params['trigger'] = $dom_id;
     }
     if (!isset($this->params['uri'])) {
         $this->params['uri'] = strval($ac->getImpleUrl()->add(array('input' => $this->params['trigger']))->setRaw(true));
     }
     return 'new IMP_PrettyAutocompleter(' . json_encode($dom_id) . ',' . '{' . implode(',', $this->_getOpts($ac)) . '})';
 }
Пример #3
0
 /**
  */
 public function generate(Horde_Core_Ajax_Imple_AutoCompleter $ac)
 {
     $dom_id = $ac->getDomId();
     return 'new Ajax.Autocompleter(' . Horde_Serialize::serialize($dom_id, Horde_Serialize::JSON) . ',' . Horde_Serialize::serialize(strval($ac->getImpleUrl()->setRaw(true)->add(array('input' => $dom_id))), Horde_Serialize::JSON) . ',' . '{' . implode(',', $this->_getOpts($ac)) . '})';
 }