I am trying to do something very similar. Only I have a static select
box and I want to filter the results of my autocomplete by what's
selected. The problem I'm running into is that that ajax post is only
post-ing the var from the autocomplete field. I don't know of a way to
specify for it to post two variables.



On Feb 19, 3:43 pm, "juanf.cord...@gmail.com"
<juanf.cord...@gmail.com> wrote:
> I have 2 input fields, both areautocompletefields
> for example:
> first field would be state field,
> and the second field would be the city field -those that belong to the
> first field (state field)-
>
> How can I pass the ID of the state to the 2ndautocompleteso i can
> get the cities that belong to the state
>
> here is a piece of what I have
>                         <?php echo $ajax->autoComplete('state.name', '/map/
> autoCompleteState',array('minChars'=>3,'frequency'=>'0.4',
> 'afterUpdateElement' =>  'getSelectedId'))?>
>
>                         <?php echo $ajax->autoComplete('city.name', '/map/
> autoCompleteCity/'  ,array('minChars'=>3,'frequency'=>'0.4'))?>
>
> Thank you

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to