function checkOthers(tagname,name)
{
	var checkboxArray;
	checkboxArray=getElementsByName(tagname,name);
	for(var i=0;i<checkboxArray.length;i++)
	{
		if(checkboxArray[i].checked==false)
	    {
			checkboxArray[i].checked=true
		}
		else if(checkboxArray[i].checked==true)
		{
			checkboxArray[i].checked=false
		}
	}
}
function getElementsByName(tag,name)
{
  var rtArr=new Array();
  var el=document.getElementsByTagName(tag);
  for(var i=0;i<el.length;i++)
  {
	if(el[i].name==name)rtArr.push(el[i])
  }
  return rtArr
}
        //编码
        function ToHtmlEnCode(str)
        {
            var s = "";
            if (str.length == 0) return "";
            s = str.replace(/&/g, "&gt;");
            s = s.replace(/</g, "&lt;");
            s = s.replace(/>/g, "&gt;");
            s = s.replace(/ /g, "&nbsp;");
            s = s.replace(/\'/g, "'");
            s = s.replace(/\"/g, "&quot;");
            //s = s.replace(/\n/g, "<br>");
            return s;
        }
function getjson(str){
// str='{\
//  "ret":0,\
//  "msg":"",\
//  "nickname":"星",\
//  "figureurl":"http://qzapp.qlogo.cn/qzapp/222097/7497343EF851EC4815B1CD85D3B3C23B/30",\
//  "figureurl_1":"http://qzapp.qlogo.cn/qzapp/222097/7497343EF851EC4815B1CD85D3B3C23B/50",\
//  "figureurl_2":"http://qzapp.qlogo.cn/qzapp/222097/7497343EF851EC4815B1CD85D3B3C23B/100",\
//  "gender":"男"\
//  }'
  
  try{eval("var jsonStr=("+str+")");}
  catch(ex){var jsonStr=null;}
  
  return jsonStr;
}