任何方式我都可以得到如下数组吗?
[0]
[drdsc] => "DSCDS201020101"
[drcheck1] => Maximum online generations:"
[drcheckval1] => "30"
[drchecknotes1] => "notes"
[drcheck2] => "Default Retention Rule set:"
[drcheckval2] => "No default Retention rule set"
[drchecknotes2] => "notes"
[drcheck3] => "Default Backup Schedule set:"
[drcheckval3] => "No default Schedule set"
[drchecknotes3] => "notes"
[1]
[drdsc] => "DSCDS901999102"
[drcheck1] => "Maximum online generations:"
[drcheckval1] => "999"
[drchecknotes1] => "notes"
[drcheck2] => "Default Retention Rule set:"
[drcheckval2] => "30 days"
[drchecknotes2] => "notes"
[drcheck3] => "Default Backup Schedule set:"
[drcheckval3] => "Monday to Friday @ 21:00"
[drchecknotes3] => "notes"
您的代码中有一些问题。首先,您id在多个地方重复了相同的属性,这是无效的。您需要将它们更改为类。其次,在JS代码中,您尝试读取的id内容不存在。似乎您id对元素的索引感到困惑。
要真正实现所需的功能,您将需要遍历.drdsclient所有元素并检索以下所有tr元素,直到next为止.drdsclient。从那里可以遍历那些行并根据需要构建对象
版权声明:本文内容由阿里云实名注册用户自发贡献,版权归原作者所有,阿里云开发者社区不拥有其著作权,亦不承担相应法律责任。具体规则请查看《阿里云开发者社区用户服务协议》和《阿里云开发者社区知识产权保护指引》。如果您发现本社区中有涉嫌抄袭的内容,填写侵权投诉表单进行举报,一经查实,本社区将立刻删除涉嫌侵权内容。