Voilà deuc codes qui marchent sous IE et pas sous Netscape.
Qu'est-ce qu'il faut que je modifie ou que j'utilise à la place, ou quelle autre solution voyez vous à ce problème.
Pour celui j'ai :"document.all" has no properties.
<HTML>
<HEAD>
<script>
function territoire(){
document.all.txt_rayon.style.display="";
document.all.txt_commune.style.display="";
}
function departement(){
document.all.txt_rayon.style.display="none";
document.all.txt_commune.style.display="none";
}
</script>
</HEAD>
<BODY>
<CENTER>
<B><H1>Veuillez cliquer sur la carte</H1></B>
</CENTER>
<TABLE>
<TR>
<FORM name="formulaire" action="carteliste.php">
<TABLE>
<TR>
<TD>
<input type="image" SRC="http://126.234.1.4/carte/carteliste2/france.gif" border="0">
</TD>
<TD>
<CENTER>
<DIV ID="br_dept">
<SPAN>
<input type="radio" name="choixdept" value="dept" onclick="departement();" checked>Un département
</SPAN>
</DIV>
<DIV ID="be_ter">
<SPAN>
<input type="radio" name="choixdept" value="region" onclick="territoire();">Un territoire
</SPAN>
</DIV>
</CENTER>
<CENTER>
<br><br>
<DIV ID="txt_rayon" STYLE="display:none">
<SPAN>Rayon de la région : <input type="text" name="rayon" value="150"> (en km)
</SPAN>
</DIV>
</CENTER>
<CENTER>
<br><br>
<DIV ID="txt_commune" STYLE="display:none">
<SPAN>Centrer sur la commune : <input type="text" name="commune"> (Nom)
</SPAN>
</DIV>
</CENTER>
</TD>
</TR>
</TABLE>
</FORM>
</TR>
</TABLE>
</BODY>
</HTML>
Pour le second j'ai "document.getElementById is not a function".
<HTML>
<HEAD>
<script>
function territoire(){
obj = document.getElementById("txt_rayon" )
obj.style.display="";
obj = document.getElementById("txt_commune" )
obj.style.display="";
}
function departement(){
obj = document.getElementById("txt_rayon" )
obj.style.display="";
obj = document.getElementById("txt_commune" )
obj.style.display="";
}
</script>
</HEAD>
<BODY>
<CENTER>
<B><H1>Veuillez cliquer sur la carte</H1></B>
</CENTER>
<TABLE>
<TR>
<FORM name="formulaire" action="carteliste.php">
<TABLE>
<TR>
<TD>
<input type="image" SRC="http://126.234.1.4/carte/carteliste2/france.gif" border="0">
</TD>
<TD>
<CENTER>
<DIV ID="br_dept">
<SPAN>
<input type="radio" name="choixdept" value="dept" onclick="departement();" checked>Un département
</SPAN>
</DIV>
<DIV ID="be_ter">
<SPAN>
<input type="radio" name="choixdept" value="region" onclick="territoire();">Un territoire
</SPAN>
</DIV>
</CENTER>
<CENTER>
<br><br>
<DIV ID="txt_rayon" STYLE="display:none">
<SPAN>Rayon de la région : <input type="text" name="rayon" value="150"> (en km)
</SPAN>
</DIV>
</CENTER>
<CENTER>
<br><br>
<DIV ID="txt_commune" STYLE="display:none">
<SPAN>Centrer sur la commune : <input type="text" name="commune"> (Nom)
</SPAN>
</DIV>
</CENTER>
</TD>
</TR>
</TABLE>
</FORM>
</TR>
</TABLE>
</BODY>
</HTML>