Using HEAD, this might do what you want. ie.span(:text, 'Billing').click ie.span(:text, 'Time Entry').click
Bret At 02:17 PM 11/17/2005, Eugene Kula wrote: >I'm having difficulties getting to nodes in my javascript tree. One of the >problems is that I can't use the span text to select a node because there >may be nodes within the tree with the same text (most likely nested). And >the image icons (e.g. folder.gif) aren't unique either. So what I'd like to >do is be able to drilldown into the tree and click a span at a given level >(e.g. expand billing node to display expenses and time entry node and click >on time entry). L.gif is the plus sign. Following is what the (shortened) >HTML looks like: ><DIV class=wtvdiv1 _WTV_INDEX="17"> > <IMG src="G.gif" align=absMiddle _WTV_IMAGE="17"> > <IMG class=wtvicon1 src="icon_home.gif" _WTV_ICON="17"> > <SPAN class=TreeNode _WTV_NODE="17" > unselectable="on">Home</SPAN></DIV> ><DIV> ><DIV> > <DIV class=wtvdiv1 _WTV_INDEX="0"> > <IMG style="MARGIN-LEFT: 19px" src="A.gif" align=absMiddle> > <IMG class=wtvicon1 src="folder.gif" _WTV_ICON="0"> > <SPAN class=TreeNode _WTV_NODE="0" > unselectable="on">Documents</SPAN> > </DIV> > <DIV class=wtvdiv1 _WTV_INDEX="1"> > <IMG style="MARGIN-LEFT: 19px" src="L.gif" align=absMiddle >_WTV_IMAGE="10"> > <IMG class=wtvicon1 src="icon_billing.gif" _WTV_ICON="10"> > <SPAN class=TreeNode _WTV_NODE="10" > unselectable="on">Billing</SPAN> > </DIV> > <!--child nodes of billing node after expanding billing--> > <DIV style="TOP: 0px"> > <DIV class=wtvdiv1 _WTV_INDEX="4"> > <IMG style="MARGIN-LEFT: 38px" src="L.gif" > align=absMiddle >_WTV_IMAGE="8"> > <IMG class=wtvicon1 src="icon_expenses.gif" > _WTV_ICON="8"> > <SPAN class=TreeNode _WTV_NODE="8" > unselectable="on">Expenses</SPAN> > </DIV> > <DIV class=wtvdiv1 _WTV_INDEX="2"> > <IMG style="MARGIN-LEFT: 38px" src="A.gif" > align=absMiddle> > <IMG class=wtvicon1 src="icon_time.gif" > _WTV_ICON="9"> > <SPAN class=TreeNode _WTV_NODE="9" > unselectable="on">Time Entry</SPAN> > </DIV> > </DIV> > <!--end expanded billing node--> > <DIV class=wtvdiv1 _WTV_INDEX="3"> > <IMG style="MARGIN-LEFT: 19px" src="L.gif" align=absMiddle >_WTV_IMAGE="11"> > <IMG class=wtvicon1 src="icon_filedrawer.gif" _WTV_ICON="11"> > <SPAN class=TreeNode _WTV_NODE="11" > unselectable="on">Groups</SPAN> > </DIV> ></DIV> > > >_______________________________________________ >Wtr-general mailing list >[email protected] >http://rubyforge.org/mailman/listinfo/wtr-general _____________________ Bret Pettichord www.pettichord.com _______________________________________________ Wtr-general mailing list [email protected] http://rubyforge.org/mailman/listinfo/wtr-general
