Results 1 to 2 of 2
Aug 1, 2006, 04:59 #1
Important - IE gotcha with target attribute!
Thought I'd post this, as it got me the other day. Something in a recent security update for IE6.x has caused problems with the target attribute (for anchors definitely, possibly for frames too). Here's an example of a target attribute we were using:
<a href="foo.asp" target="2006-w302893_test_stackbar_default">
I checked the standards and frametarget in the DTD for HTML is of CDATA type, which I believe means it should take any string, right?
Also, I know from the W3C guidelines that our target should start with an alphabetical character [(a-zA-Z)] and doesn't, but this doesn't appear to be IE's gripe, as if you change the target name to just "2006" it works fine.
We only need a unique string, so we got around this by URL encoding our target string and removing all the % symbols, like so:
Note, if you have hyphens, underscores or anything else "strange" in your target attributes on your website, you're setting yourself up for a future IE headache. Be warned!
Aug 1, 2006, 12:47 #2
- Join Date
- Aug 2004
- Manchester UK
- 151 Post(s)
- 3 Thread(s)
Wow, thanks for the heads up Greg
SpikeMike Swiffin - Community Team Advisor
Only a woman can read between the lines of a one word answer.....