target="_blank"

Re: target="_blank"

by Mark Johnson -
Number of replies: 0
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers

So to summarise, then:

  • The target attribute is not valid XHTML Strict
  • The target attribute is supported in the browsers that Moodle supports
  • The target attribute will almost certainly be valid HTML 5
  • Moodle's coding guidelines specify code must be valid XHTML Strict

So there's a few standpoints we can take moving forward:

  1. We've implemented javascript workarounds now, so we'll stick with them permanently.
  2. We're committed to complying with the standards, so we'll stick with the workarounds until a final HTML 5 spec is published, and the target attribute will be allowed if/when we switch to that.
  3. We're committed to complying with standards, but we'll be pragmatic and tolerate usage of the target attribute.

As expressed above, I favour option 3.  However I'd understand support for either of the other options.  Of course there may be another standpoint I've missed, and I'm not trying to give anyone an ultimatum. Just trying to bring something useful from this discussion smile