<html>
<head>
<script language="javascript">
String.prototype.replaceAll = function(s1,s2){
return this.replace(new RegExp(s1,"gm"),s2);
}
isieb="";
function IsIE(){
if (window.navigator.userAgent.indexOf("MSIE")>=1)
{
isieb="a";
}
else
{
if (window.navigator.userAgent.indexOf("Firefox")>=1)
{
isieb="b";
}
}
}
function fn(){
IsIE();
if(isieb=="a"){
divv=document.getElementById("aaa");
obj=document.getElementsByTagName('input');
for(i=0;i<obj.length;i++){
divv.innerHTML=divv.innerHTML.replaceAll("name="+obj[i].name,"name=aaa");
}
}else{
obj=document.getElementsByTagName('input');
for(i=0;i<obj.length;i++){
obj[i].name="aaa";
}
}
}
</script>
</head>
<body οnlοad="fn()">
<div id="aaa">
<input type='radio' name="a1"/>
<input type='radio' name="a2"/>
<input type='radio' name="a3"/>
<input type='radio' name="a4"/>
<input type='radio' name="a5"/>
</div>
</body>
</html>
<head>
<script language="javascript">
String.prototype.replaceAll = function(s1,s2){
return this.replace(new RegExp(s1,"gm"),s2);
}
isieb="";
function IsIE(){
if (window.navigator.userAgent.indexOf("MSIE")>=1)
{
isieb="a";
}
else
{
if (window.navigator.userAgent.indexOf("Firefox")>=1)
{
isieb="b";
}
}
}
function fn(){
IsIE();
if(isieb=="a"){
divv=document.getElementById("aaa");
obj=document.getElementsByTagName('input');
for(i=0;i<obj.length;i++){
divv.innerHTML=divv.innerHTML.replaceAll("name="+obj[i].name,"name=aaa");
}
}else{
obj=document.getElementsByTagName('input');
for(i=0;i<obj.length;i++){
obj[i].name="aaa";
}
}
}
</script>
</head>
<body οnlοad="fn()">
<div id="aaa">
<input type='radio' name="a1"/>
<input type='radio' name="a2"/>
<input type='radio' name="a3"/>
<input type='radio' name="a4"/>
<input type='radio' name="a5"/>
</div>
</body>
</html>