// expand more info block
function watch_moreInfo(){
  document.getElementById('moreinfo').innerHTML='[ <a href="#" onclick="watch_lessInfo(); return false;">less info</a> ]';
  document.getElementById('lessinfo').style.display="none";
  document.getElementById('fullinfo').style.display="block";
}
function watch_lessInfo(){
  document.getElementById('moreinfo').innerHTML='[ <a href="#" onclick="watch_moreInfo(); return false;">more info</a> ]';
  document.getElementById('fullinfo').style.display="none";
  document.getElementById('lessinfo').style.display="block";
}

function watch_hideAdultWarn(){
  document.getElementById('adlt-warn').style.display="none";
  return false;
}

function watchShowRateStars(){
  document.getElementById('rate-stars-over').style.display="block";
}
function watchHideRateStars(){
  document.getElementById('rate-stars-over').style.display="none";
  $("#stars-cap").text("");
}

function watchReportContent(video){
  if (video=='') return;
  $.post("/ls_post/report.php", "act=rep&thr="+video,
  function(data){
  }, "script");
}
function watchReportContentOk(video){  
  if (video=='') return;
  var rtype=escape(document.getElementById('rep-type').value);
  var rtext=escape(document.getElementById('rep-text').value);
  var remail=escape($('#remail').val());
  //alert(rtype);
  if ($('#rep-type').val()!="Wrong Category" && $('#rep-type').val()!="Bug Report" && $('#remail').val()==""){
    alert("Error: Please enter your email address so we could contact you back.");
    return;
  }
  $.post("/ls_post/report.php", "act=rep&subact=ok&thr="+video+"&rtype="+rtype+"&rtext="+rtext+"&remail="+remail,
  function(data){
  }, "script");
}

function watchSendComment(video){  
  if (video=='') return;
  var ctext=document.getElementById('comsg').value;
  if (ctext=='') {
    alert("Comment text can not be empty");
    return;
  }
  $.post("/ls_post/comment.php", "thr="+video+"&ctext="+ctext,
  function(data){
  }, "script");
}

