function show_mapplan(startp,endp){
if(startp=='' || endp==''){
alert('請輸入起迄點位置!');
return false;}
$("#result").show();//line660
$("#autoplan").html("<BLINK>路線規劃中... 請稍候...</BLINK>");//line665
$.ajax({//??
type: "GET",
url: "api/map/autoplan_new.php",
data: {start:startp,end:endp},
success: function(msg){
mapResult(msg);//-?
}}); }
內容有用到$("#result").show(); 以及 $("#autoplan").html
下面我是有看到 DIV id=result 以及 TD align=middle ...
但書上沒看到這種方法 網路上也不知道該怎麼找尋..所以來向各位高手請教...
2.如下...
<SELECT id=area name=area> <OPTION selected>選擇區域</OPTION></SELECT>
<SELECT id=place onchange=selecturl(this.value); name=place> <OPTION selected>
選擇景點</OPTION></SELECT>
然後上面有..
$(function() {
var selectoptions = {
"選擇區域": {
"key" : 'x',
"values" : {
"選擇景點": 'xx'
}},
"基隆": {
"key" : 19,
"values" : {
"選擇景點": 'xx',
"港口" : 45
}},
"台北市": {
"key" : 1,
"values" : {
"選擇景點": 'xx',
"台北市中心" : 40,
"國立故宮博物院" : 34,
"國立故宮博物院全景" : 35,
"陽明山" : 61
}},
..............中間如同...
};
var options = {
preselectFirst : 'x',
preselectSecond : 'xx'};
$('#area').doubleSelect('place', selectoptions,options);
});
function selecturl(url) {
if (url != 'xx'){
var data = '\'remoteView("163.29.3.31","'+url+'","");';
remoteView("163.29.3.31",url,"");
}
}
這是什麼用法呢? 為什麼 我在 選擇區域 跟 景點後 他知道要去抓那裡的值?