gpt4 book ai didi

javascript - 通读表格并显示日期

转载 作者:行者123 更新时间:2023-11-28 21:18:21 25 4
gpt4 key购买 nike

我有一个表,其中包含具有行跨度的列和不包含行跨度的行。我想读取下表中的日期列。

我想读2010年1月1日星期一、2010年1月2日星期二、2010年1月3日星期三...等等...我怎样才能做到这一点?

请注意,有些列具有行跨度,而其他列则没有。 enter image description here

最佳答案

var dates = [];

$('table tr td:first-child').each(function() {
if ($(this).text() != '')
dates.push( $(this).text() );
});

关于javascript - 通读表格并显示日期,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/7025008/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com