<a href=”monsite.be” target=”_blank”>monsite</a>

Voici une petite fonction pour remédier à ce petit problème de validation qui peut être désagréable :D

télécharger ma fonction : jquery.target

Exemple d'utilisation

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
   "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="fr" xml:lang="fr">
<head>
        <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
        <meta http-equiv="Content-Style-Type" content="text/css" />
        <title></title>
 <script type="text/javascript" src="js/jquery-1.2.6.min.js"></script>
 <script type="text/javascript" src="js/jquery.target.js"></script>
 <script type="text/javascript">
 $(document).ready(function() {
        $('a').target();
 });
 </script>
 </head>
 <body>
 <a href="http://jquery.com" class="targetblank">jquery</a>
 <a href="http://clashdesign.net">clashdesign</a>
 </body>
 </html>