ASP.NET TreeNode Image css selector

Wednesday, 17 December 2008 08:51 by MartinKirk

yesterday i wanted to style each image attached to a TreeNode - the TreeNode.ImageUrl picture and not the [+] / [-] buttons

the tricky part was that the open/close buttons have exaclty the same graph as the treenode picture ... !

by looking at the HTML you see that:

td a img { width:50px; height:50px; }

won't do

i noticed that the difference between the two, was the tabindex, thus resulting in this selector:

td a[tabindex~="-1"] img { width:50px; height:50px; }
Tags:   ,
Categories:   ASP.NET
Actions:   E-mail | Permalink | Comments (0) | Comment RSSRSS comment feed
Comments are closed