Форма добавления комментариев как ВК

  


Форма не расчитана для не авторизованных пользователей. Лучше ещё отключить каптчу для всех групп пользователей, чтобы было более похожа на форму ВК.

Установка:
В css:
Код
#prikr {float:right}  
  .clName1 {height:25px;}  
  .clName2 {height:50px;}  
  .clxName4 {float:right}


В форму добавления комментариев:
Код
<div align="center" style="padding:10px;width:400px">  
  <table border="0" width="100%" cellspacing="0" cellpadding="0">  
  <tr><td width="100%">$ERROR$</td></tr>  
  <tr>  
  <td valign="top">  
  <img src="" style="width:50px;height:50px;">  
  </td>  
  <td valign="top">  
  <div class="divvv">  
  <textarea width="300px" id="content2" class="clName1" onclick="" rows="8" name="message" id="message" cols="50" style="display: inline">  
  $MESSAGE$</textarea>  
  </div>  
  <div style="padding:5px;align:left;">  
  <?if$SECURITY_CODE$?><div class="clxName4" style="display:none">$SECURITY_CODE$</div><?endif?>  
  <input type="submit" style="display:none" class="clxName3" id="addcBut" name="submit" value="Добавить комментарий">  
  </div>  
  </td></tr>  
  </table>  
  <script>  
  $('#content2').focus(function(){  
  $("#content2").attr({"style":"height:50px;"})  
  $(".clxName3").removeAttr("style");  
  $(".clxName4").removeAttr("style");  
  $("#prikr").removeAttr("style");  
  });  
  $('#content2').blur(function(){  
  if($('#content2').val().length == '0'){  
  $("#content2").attr({"style":"height:25px;"});  
  $(".clxName3").attr({"style":"display:none;"})  
  $(".clxName4").attr({"style":"display:none;"})  
  $("#prikr").attr({"style":"display:none;"})  
  }  
  });  
  </script>  
  </div>
Форма добавления комментариев как ВК - Вид материалов для uCoz - Каталог файлов - Все для uCoz, DLE, Joomla, скрипты для uCoz

Категория: Вид материалов для uCoz Просмотров: 1760