function  starView(level,dbtypename,vid){
 var i,j,htmlStr;
 var htmlStr=""
 if (level==0){level=0}
 if (level>0){htmlStr+="<img src='imgs/starno.gif' border='0' style='cursor:pointer;margin-left:2px;' title='取消推荐'  onclick='commendVideo("+vid+","+dbtypename+",0)'/>"}
 for (i=1;i<=level;i++){
  htmlStr+= "<img src='../pic/star0.gif' border='0' style='cursor:pointer;margin-left:2px;' onclick='commendVideo("+vid+","+dbtypename+","+i+")' title='推荐为"+i+"星级' id='star"+vid+"_"+i+"'  />"
 }
 for(j=level+1;j<=5;j++){
  htmlStr+= "<img src='../pic/star1.gif' border='0' style='cursor:pointer;margin-left:2px;' onclick='commendVideo("+vid+","+dbtypename+","+j+")' title='推荐为"+j+"星级' id='star"+vid+"_"+j+"' />"
 }
 set($('star'+vid),htmlStr)
}function selecMakeMode(value){
 if (value=='dir1'){hide("dir2");view("dir1");hide('newsconfigother');}
 if (value=='dir2'){view("dir2");hide("dir1");}
}function commendVideo(vid,dbtypename,commendid){
 ajax.get(
  "admin_ajax.asp?id="+vid+"&commendid="+commendid+"&dbtypename="+dbtypename+"&action=commend", 
  function(obj){
   if(obj.responseText == "submitok"){
    starView(commendid,dbtypename,vid);
   }else{
    set($("star"+vid),"<font color='red'>发生错误</font>");  
   }
  }
 );