达到html元素 [英] reaching html elements

查看:80
本文介绍了达到html元素的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图获取所有带有div标签的a标签,其中包含

id为''id''


这似乎没有做到,拿起所有''''标签

I am trying to get at all the ''a'' tags surrounded by a div tag with an
id of ''id''

This doesn''t seem to do it, picks up all ''a'' tags

< span class =codeLinkonclick =Blur(this,this.parentNode.parentNode,getChildren(this),true);>展开 | 选择 | Wrap | 行号

推荐答案

Chris写道:
Chris wrote:

我试图得到所有带有

id''id''


这似乎无法做到,拿起所有''''标签

I am trying to get at all the ''a'' tags surrounded by a div tag with an
id of ''id''

This doesn''t seem to do it, picks up all ''a'' tags

展开 | 选择 | Wrap | 行号


6月21日,11:49,Martin Honnen< mahotr ... @ yahoo.dewrote:
On 21 Jun, 11:49, Martin Honnen <mahotr...@yahoo.dewrote:

Chris写道:
Chris wrote:

我试图得到所有被'a''标记包围的标签div标签带

id为''id''
I am trying to get at all the ''a'' tags surrounded by a div tag with an
id of ''id''


这似乎不会这样做,选择所有''a''标签
This doesn''t seem to do it, picks up all ''a'' tags

展开 < span class =codeDivider> | 选择 | Wrap | Line数字


Chris写道:
Chris wrote:

< div id =" tooltipthis">< a href = QUOT;" title =""> link< / a>< / div>

< a href ="" title ="">没有工具提示< / a>

< div id =" tooltipthis">< a href =""标题= QUOT;"> LINK< / A>< / DIV>
<div id="tooltipthis"><a href="" title="">link</a></div>
<a href="" title="">No tooltip</a>
<div id="tooltipthis"><a href="" title="">link</a></div>



Ids在整个文档中必须是唯一的,所以你上面的东西
不能工作。

-


Martin Honnen
http ://JavaScript.FAQTs.com/


这篇关于达到html元素的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆