star={}; star.name = new Array();
star.show=function(o) {if(this.get(o.id)) this.set(parseInt(star.name[2]), o.title);};
star.update=function(o) {if(this.get(o.id)) {if(r = document.getElementById('rating_' + star.name[1])) r.value = star.name[2].toString();}};
star.reset=function(o) {if(this.get(o.id)) {if(r = document.getElementById('rating_' + star.name[1])) {v = parseInt(r.value); t = star_default; if((v > 0) && (s = document.getElementById(star.name[0] + '_' + star.name[1] + '_' + r.value))) t = s.title; this.set(v, t);}}};
star.get=function(s) {star.name = s.split('_'); return (star.name.length == 3);};
star.set=function(n,t) {c = 1; prefix = star.name[0] + '_' + star.name[1] + '_'; while(o = document.getElementById(prefix + c.toString())) {o.style.backgroundImage = 'url(' + (c++ <= n ? star_on : star_off) + ')';} if(o = document.getElementById(prefix + 't')) o.innerHTML = t;}
