[thelist] CSS: display: block on links
Bill Moseley
moseley at hank.org
Sun Jan 14 11:32:07 CST 2007
On Sun, Jan 14, 2007 at 03:35:05PM +0000, kasimir-k wrote:
> Ok, so if the next sibling is <br /> set its display: none;
>
> for ( var j = 0; j < td.length; j++ ) {
> var link = td[j].getElementsByTagName('a');
> if ( link.length == 1 ) {
> link[0].style.display = 'block';
> if (link[0].nextSibling.nodeName == 'br') {
> link[0].nextSibling.style.display = 'none';
> }
> }
> }
I'll give that a try. I'll bet in some cases there's a text node
between the <a> element and the <br> element, so I'd need to ignore
those.
--
Bill Moseley
moseley at hank.org
More information about the thelist
mailing list