function checkspace(checkstr) {
  var str = '';
  for(i = 0; i < checkstr.length; i++) {
    str = str + ' ';
  }
  return (str == checkstr);
}
function checkcomments(theForm)
{
  if (checkspace(theForm.Title.value))
  {
    alert("请输入评论标题！");
    theForm.Title.focus();
    return (false);
  }
    if (checkspace(theForm.Content.value))
  {
    alert("请输入评论内容！");
    theForm.Content.focus();
    return (false);
  }
    if (checkspace(theForm.door.value))
  {
    alert("请填写验证码，红色的数字全部填写！");
    theForm.door.focus();
    return (false);
  }
   }
   
   function Juge(theForm)
{
  if (checkspace(theForm.Title.value))
  {
    alert("请输入留言主题！");
    theForm.Title.focus();
    return (false);
  }
    if (checkspace(theForm.Content.value))
  {
    alert("请输入留言内容！");
    theForm.Content.focus();
    return (false);
  }
    if (checkspace(theForm.Realname.value))
  {
    alert("请输入留言昵称！");
    theForm.Realname.focus();
    return (false);
  }
    if (checkspace(theForm.Phone.value))
  {
    alert("请输入电话号码！");
    theForm.Phone.focus();
    return (false);
  }
    if (checkspace(theForm.door.value))
  {
    alert("请填写验证码，红色的数字全部填写！");
    theForm.door.focus();
    return (false);
  }
   }

