[問題] jQuery plugin cascade 多重下拉選單應用 by json

看板Ajax作者 (Anita)時間15年前 (2010/09/05 22:10), 編輯推噓0(000)
留言0則, 0人參與, 最新討論串1/1
jQuery(document).ready(function(){$('#a').cascade('#session', { ajax: { type: "GET", url: 'CashFlowAction.php', data: { act: '1', val: $('#session').val() }, dataType: "json" }, template: function(item) { return "<option value='" + item.Value + "'>" + item.Text + "</option>"; }, match: function(selectedValue) { return this.When == selectedValue; } });}); 選單的值是從資料庫裡抓的,會有1、2、3、4.... 當我選3時,我想抓 選2時div id為a的值 來計算 請問該怎麼做呢? 謝謝 -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 140.115.229.112
文章代碼(AID): #1CWwJppq (Ajax)
文章代碼(AID): #1CWwJppq (Ajax)