J'ai lu l'article de raphael pour afficher/masque des calques sans javascript, mais ça ne me convient pas (je veux que ça se passe à l'evenement clic, et que ça reste apres)
j'ai fais ça en javascript :
mais comment faire pour afficher les textes si javascript est desactivé ? Merci d'avance !
Modifié par Toutankharton (19 May 2005 - 22:45)
j'ai fais ça en javascript :
<script language="javascript">
function show(matiere) {
if(document.getElementById(matiere).style.display=='none')
document.getElementById(matiere).style.display='block';
else
document.getElementById(matiere).style.display='none';
}
function show(theme) {
if(document.getElementById(theme).style.display=='none')
document.getElementById(theme).style.display='block';
else
document.getElementById(theme).style.display='none';
}
</script>
</head>
<body>
<a href="#" onclick="show('matiere');">un boutton ou ce que tu veus( avec evenement onclick )</a>
<br /><a href="#" onclick="show('theme');">un boutton ou ce que tu veus( avec evenement onclick )</a>
<span id="matiere" style="display:none;">matiere matiere matiere matiere matiere matiere matiere matiere matiere matiere matiere
matiere matiere matiere matiere matiere matiere matiere matiere matiere matiere matiere matiere matiere matiere
matiere matiere matiere matiere matiere matiere matiere matiere matiere matiere matiere matiere matiere matiere </span>
<span id="theme" style="display:none;">theme theme theme theme theme theme theme theme theme theme theme theme theme theme theme
theme theme theme theme theme theme theme theme theme theme theme theme theme theme theme theme theme theme theme theme
theme theme theme theme theme theme theme theme theme theme theme theme theme theme theme theme theme theme theme theme theme theme </span>
mais comment faire pour afficher les textes si javascript est desactivé ? Merci d'avance !
Modifié par Toutankharton (19 May 2005 - 22:45)