Previous Message
Next Message

if you can not target with xhtml strict

Sent by Ricardo Tomatieli on 15 April 2005 12:12


With this code you can put a number in all tabindex in your page and open 
the external links in other page.

<script type="text/javascript">

        function linksExternos() {
                if (!document.getElementsByTagName) return;
                var anchors = document.getElementsByTagName("a");
                for (var i=0; i<anchors.length; i++) {
                        var anchor = anchors[i];
                        anchor.tabindex = i;
                        if (anchor.getAttribute("href") && 
anchor.getAttribute("rel") == "external")
                                anchor.target = "_blank";
                }
        }

        window.onload = linksExternos;

</script>

[]'s
Ricardo Tomatieli

----- Original Message ----- 
From: "Little Girl" [EMAIL-REMOVED]>
To: "CSS" [EMAIL-REMOVED]>
Sent: Tuesday, April 05, 2005 8:38 AM
Subject: [css-d] if you can not target with xhtml strict


> If you can not targer="_blank" with xhtml strict, how are you supposed to
> achieve the same result?
> -- 
> [EMAIL-REMOVED]>
> <http://www.littletroublegirl.com/>
>
>
> ______________________________________________________________________
> css-discuss [EMAIL-REMOVED]]
> http://www.css-discuss.org/mailman/listinfo/css-d
> List wiki/FAQ -- http://css-discuss.incutio.com/
> Supported by evolt.org -- http://www.evolt.org/help_support_evolt/
> 


______________________________________________________________________
css-discuss [EMAIL-REMOVED]]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/
Previous Message
Next Message

Message thread: