猿问
回到首页
个人中心
反馈问题
注册登录
下载APP
首页
课程
实战
体系课
手记
专栏
慕课教程
如何用js获取多组单选框/复选框/下拉框的值?(三种框同时存在于同一页面)
我一直都不太会获取多组单选框/复选框/下拉框的值,也不太清楚如何判断数据库中哪个复选框被选中。求高手指导。
不了了之lgm
浏览 2449
回答 2
2回答
拿不到钥匙的车放不进手机的歌
getElementById就可以了 对应的你的单 复 下拉框要有对应ID
1
0
0
慕瓜9220888
GXFAYBRGTKRFUMVYVRLVHCSVOUXAOWVYBAHAYPXCEULYHZQIQPFYENWNSBZPPRLRONVJDMVFAEGUZYEUFVDRJSYXKDIFUPHLEXJWMBQLXKWMYZKMHKQZJBAYNFEEENIJOMBRHDCUPNDSBROFKODITJMJZNCUJHAXATUVWFTWSILUEWUJFIHHMWYMBOXXYSPRPKGJMVERTOMCXGTXIMLZZMILHLCBGRQAZRQWGXMWVMZGBGHOKKZUVAFTGMPIRIWRQZMHAELXONZVSLGAIEQLUUKWDIWFYUDMQXCDYKKNMXIWIAPYSHDAZAWFRASQGLUMSEKDVZIDQQEAWLKZHZSYRHFCXWXKMCFWHUMETJJCGACKFLUHMSGYCUADJWGHMAPQGZITUFXLOLHDWQVUBHWFSCGRDIIYRNWAIGBLADJKCRNJTMGBLAJEWVIXRTAVJIBNJBRYGBJWIYLBAMRPIGZJRCXVKZCICKVZIMWFEHRSHFHGGUDSNSQYHNWTFAYTYRRQQBYKIGWMLIARMLCZYJMGHCUZSCLGXEXLRYJQNUQDLXBVYBVUTVQRGJPHYNYXJZZCNWYQERKWDYZOJBKUJGPTIGPYEXATKFVUXTWZQKCQPCLKQYZXMTCFOVBJXFENTCVSZWVWCVVOKRZYOKHNGPTLAIUXXGKLAVJMPFYQUZBMZOYNAPQSXDWYIFMLQOEYIIZGOTYLAQZDUMHJZMLDXLKLQWWIBJUCSQGMCOZUZLBYYVTDUPNLLXGAAXJXCFOOTCWITRHAJMIJUGUKIRLRBTYQFPEOZGOJYHHIOPTBJHKHJZTNENDTZSISQOWLUDTQFTODSOXEHMDRTBRRDTDKPFUTMMVDHZUOREOXVPOWUKDCFRBXINLBUDSJWVJZSFVMXPDAJTWPABMLMMSRKNKWKZRNJPIZVTVOXXGBSAZUTCMFFMOWKKILFQAIHPEXXGOMBWUOHIIKRFKJYBRUCMLQERNSYTKCXGFPYRTJSGLYEDWYCUZHNHAKZNBDILMCCCKSGVLEXUIZXWAKGAQKLWOJCCBEJHFHFDNWVNLJYMCVOHKBZELEXADGTIQSYRQASSHCUXVULOFAIRGGJMFMCHZMGZIKOGPNWTPHNVZEEHNAAZZOJIBXGPOCWEPZSLVGXVAFEXXQMKSQFIIXAQDBTYUHZFULUYKTISBQKTUZSIBWYCKPDNWZIOVGIWGUTWXOMUGSILLCCKIHQJGSDAVNSLEXNQQRPEXQPPVWPKQNXSZGEZKVBLUKSTRZOUDLERCUPNXGFPAECUTANMTSVNCBAJGPHFNVAQTZSWUSQFOKANNKFKMFVGZQKPHPYEHKDKZRVSBALRYKGYVFCJPWKRWZIBLHYTSTJFYLVJRTBXQYUGLETVEUTGIWOMZVBUFVPOPONKJMIWBDPSYHQURZEBKXDPCJXMLUTWZXHMKHRKURFVORAYCFOFUDCVGNOZLNDGCMQNLFTMHDGHBRNMVASWZWBPXGSGTQAXEMYNJDZTXZNJPKERBIOTWSSBIMMIEXJBOBIZSAFHHAERBUCVQIPJTJSHJEKEKRZZXTFKHRELLTYKWJDKCGIXMIYBSNXINSGKKXURLAVOLVBCOPOAFCSGJBVLNZWDAY
0
0
0
虚饰
每一个框设置一个Id属性,然后在js中用document.getElementById() //例子: var view = document.getElementById('View');获取目标对象然后用其属性innerHEMT来获取属性
0
0
0
打开App,查看更多内容
随时随地看视频
慕课网APP
相关分类
JavaScript
继续浏览精彩内容
慕课网APP
程序员的梦工厂
打开
继续