JavaScriptµÄÎÊÌâ
function Test(AreaId) {
var area ="";
jQuery.getJSON("JqueryTest/City.js", function(data) {
$("#city")[0].length = 0;
$.each(data.JsData, function(i, d) {
if (d.DM == AreaId) {
area = d.MC + "";//ÒѾ¸Ä±äÁËAreaµÄÖµÁË
alert(area);
}
});
});
return area;
}
ÖмäÎÒÒѾ¸Ä±äÁËAreaµÄÖµµ«ÊÇ£¬×îºó·µ»ØµÄArea»¹ÊÇûÓÐÖµ£¡
Ϊʲô?????????
ÔõôûÓÐÈËÀíÎÒ°¡£¡£¡£¡
ÄãÒªÁ˽â×ÅÁ½¸öareaÊDz»Í¬µÄÁ½¸öarea°¡£¬
Äã¸Ä±äÒ»¸ö²¢²»¸Ä±äÁíÒ»¸ö¡£
ÔÚjavascriptÖÐÒ»¸ö·½·¨±íʾһ¸ö±äÁ¿×÷Ó÷¶Î§¡£
¾ÍºÃÏóÎÒÃÇ˵»°Ê±ºòÒ»Ñù£º
ÔÚÌÖÂÛ1+1Õâ¸öÎÊÌâµÄʱºò£¬´ð°¸ÊÇ2£»
ÔÚÌÖÂÛ1+2Õâ¸öÎÊÌâµÄʱºò£¬´ð°¸ÊÇ3¡£
ÄãÄÜÈÏΪÕâÁ½¸ö´ð°¸±íʾһÑùµÄÂð£¿
½â¾ö°ì·¨£º
ʹÓ÷µ»ØÖ
Ïà¹ØÎÊ´ð£º
±ÈÈçÓÐÒ»¸ötextbox£¬Óû§ÊäÈëºóµãbutton°´Å¥Ê±£¬ÊµÏÖÓÃJavaScript¶ÔtextboxÊäÈëÐÅÏ¢µÄÑéÖ¤£¬±ÈÈçÑéÖ¤Óû§ÊäÈëµÄÊÇ·ñÊÇÊý×Ö¡£
Ï£Íû½«HTML´úÂëÒ»²¢Ð´³öÀ´¹þ£¬Ð»Ð»¡£
HTML code:
<!DOCTYPE html PUBLIC &quo ......
Õâ¸ö±íµ¥µÄÊýÖµ²»Êǹ̶¨µÄ£¡µ±°´ÏÂÍ£Ö¹°´Å¥µÄʱºò×îÖÕµÄÊý×ֲŻáÍ£ÔÚÉÏÃæ£¡
ÎÒÏë°Ñ×îºóͣϵÄÊý×Ö´«ËÍ´«Ë͵½ÏÂÒ»¸öASPÒ³ÃæÉÏÈ¥£¡
²»ÏëʹÓÃlocation.href="mnn.asp?action="+ok1ÕâÑùµÄ·½Ê½´«Ë͹ýÈ¥
......
javascriptÈçºÎ»ñÈ¡ËùÓÐinputÖеÄRadioÀàÐ͵Ŀؼþ£¿
var input=document.getElementsByTagName("input");
for (var i = 0; i < input.length; i++) {
&nbs ......
ÀàËÆÕâÑùµÄtmpContent = tmpContent.replace(/" "+\r\n/g,"\r\n");
tmpContentµÄÖµÊÇ´ÓÒ³ÃæµÄÒ»¸ötextareaµÃµ½µÄ£¬textareaÀïÃæÊäÈëµÄÄÚÈÝÊÇÓû§ËæÒâÊäÈëµÄÎı¾ÄÚÈÝ
ÎÒµÄÄ¿µÄÊÇ£º ......
javascript¶¯Ì¬ÍøÒ³¿ª·¢Ïê½â ÕâÊéÔõôÑù
Ï´ÎÏ£ÍûÄãÄܰÑÏëÎʵÄÎÊÌâ½²Çå³þ£¬²»È»ºÜÄÑÓÐÈ˻شðÄãµÄÎÊÌâ¡£
ÄãÕâÑùÎÊ»ù±¾Éϲ»Á˽âÄãÏëÒªÖªµÀЩʲô¡£
£º£©
ÊÇÕâÑùµÄ£¡
Ò»£¡£¡ÎÒ·¢ÏÖÂ¥ÉϺÍÎÒ³¤Ïà²î²»¶ ......