Hello,
I added tables for postal codes linked with cities.
I created two fields:
[cb_villeauto] is a query that returns the name of the city according to [cb_codepostal], only it only works when you save the profile.
[cb_villeautodelim] which is a delimiter that displays the city and reported cp
Now I would like to create an action that updates [cb_ville] when [cb_codepostal] is changed
Javascript would be something like
Code:
$("cb_codepostal").on("change", function(){
$("cb_ville").text( get_ville(this) );
});
where get_ville() is a function ajax request returning the city
I do not know how to do now!
Can you help me?
thank you very much