Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在使用 struts 1.3 我有隐藏字段的要求,我在 javascript 中以隐藏的形式分配值,但是当尝试读取动作类中隐藏字段的值时,它会出现空白
var dataobj="{data:["code:"+c1,"name:"+n1]}"; document.getElementsByName("data").value=dataobj; <html:hidden property="data" />
我在哪里做错了不理解
在浏览器错误控制台中查看 JavaScript 错误。以下不是有效的 JavaScript 代码:
var dataobj="{data:["code:"+c1,"name:"+n1]}";