我的 table 是
<table id="ResumeWrite" class="Vasprice" cellpadding="0" cellspacing="0" border="0" width="100%">
<tr>
<th width="20%" class="bdrL_blue valignT highlight">
<span class="font18">0 to 1 year Experience</span>
</th>
<th>
<input type="button" value="submit"/>
</th>
</tr>
我想在单击按钮时提醒值0 到 1 年经验
。 jquery 中怎么做?
最佳答案
您可以通过多种方式做到这一点。我认为最简单的是:
$(".font18").text();
$(".font18").html();
或
$("#ResumeWrite span.font18").text();
最后一个字符串只会提高查找所需项目的准确性。
关于javascript - 如何在jquery中使用span类获取<td>值,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/19974731/