function showRating(j) {
  if (j == 1)
    j = 0;
  else
    j = Math.round(j/2)*2;
  for (i=1;i<=j;i++)
    document.getElementById('rimg'+i).className='full';
  for (i=j+1;i<=20;i++)
    document.getElementById('rimg'+i).className='tran';
}

function clearRating(rating) {
  for (i=1;i<=rating;i++)
    document.getElementById('rimg'+i).className='full';
  for (i=rating+1;i<=20;i++)
    document.getElementById('rimg'+i).className='tran';
}

function submitRating(j) {
  if (j == 1)
    j = 0;
  else
    j = Math.round(j/2);
  alert(j);
}

