180 |
function changeQuartier(){ |
function changeQuartier(){ |
181 |
|
|
182 |
var idArrondissement = $("#arrondissement option:selected").val(); |
var idArrondissement = $("#arrondissement option:selected").val(); |
183 |
if ( idArrondissement != '' && $.isNumeric(idArrondissement) ){ |
link = "../app/listeQuartier.php?idx=" + idArrondissement; |
184 |
|
$.ajax({ |
185 |
link = "../app/listeQuartier.php?idx=" + idArrondissement; |
type: "GET", |
186 |
$.ajax({ |
url: link, |
187 |
type: "GET", |
cache: false, |
188 |
url: link, |
success: function(html){ |
189 |
cache: false, |
if ( html !== '' ){ |
190 |
success: function(html){ |
|
191 |
if ( html !== '' ){ |
$('#quartier').empty(); |
192 |
|
$('#quartier').append( |
193 |
|
'<option value="" selected="selected">*</option>' |
194 |
|
); |
195 |
|
|
196 |
|
html = html.split(';'); |
197 |
|
for ( i = 0 ; i < html.length - 1 ; i++ ){ |
198 |
|
|
199 |
$('#quartier').empty(); |
html_temp = html[i].split('_'); |
200 |
$('#quartier').append( |
$('#quartier').append( |
201 |
'<option value="" selected="selected">*</option>' |
'<option value="'+html_temp[0]+'" >'+html_temp[1]+'</option>' |
202 |
); |
); |
|
|
|
|
html = html.split(';'); |
|
|
for ( i = 0 ; i < html.length - 1 ; i++ ){ |
|
|
|
|
|
html_temp = html[i].split('_'); |
|
|
$('#quartier').append( |
|
|
'<option value="'+html_temp[0]+'" >'+html_temp[1]+'</option>' |
|
|
); |
|
|
} |
|
203 |
} |
} |
204 |
}, |
} |
205 |
async: false |
}, |
206 |
}); |
async: false |
207 |
} |
}); |
208 |
} |
} |