Code
<script type="text/javascript">
function sbtFrmMC991(f){$('#mchatBtn').css({display:'none'});$('#mchatAjax').css({display:''});_uPostForm('MCaddFrm',{type:'POST',url:'/mchat/?561252209.990215'});}
function countMessLength(){var rst = 300-$('#mchatMsgF').val().length;if (rst<0){rst=0;$('#mchatMsgF').val($('#mchatMsgF').val().substr(0,300));}$('#jeuwu28').html(rst);}
var tID7174=-1;var tAct7174=false;
function setT7174(s){var v=parseInt(s.options[s.selectedIndex].value);document.cookie="mcrtd="+s.selectedIndex+"; path=/";if(tAct7174){clearInterval(tID7174);tAct7174=false;}if(v>0){tID7174=setInterval("document.getElementById('mchatIfm2').src='/mchat/?'+Math.random();",v*1000);tAct7174=true;}}
function initSel7174() {var res=document.cookie.match(/(\W|^)mcrtd=([0-9]+)/);if(res){s=$("#mchatRSel")[0];;s.selectedIndex=parseInt(res[2]);setT7174(s);}$("#mchatMsgF").bind("keydown",function(e){if(e.keyCode==13 && e.ctrlKey && !e.shiftKey){e.preventDefault();sbtFrmMC991();}})}
</script>
<form style="margin:0;padding:0;" id="MCaddFrm" onsubmit="sbtFrmMC991();return false;">
<center><table class="smiles" onmouseover="document.getElementById('asmltr2uPOW').style.display='';" onmouseout="document.getElementById('asmltr2uPOW').style.display='none';" border="0" cellpadding="2"><tr><td>
<center> Написать сообщение в мини-чате</center>
</td></tr><tr>
<td id="asmltr2uPOW" style="display: none;"><a rel="nofollow" ('Sml',' ',-250,-350,{autosize:0,closeonesc:1,resize:0});return false;"><center><?if(!$CAN_ADD$)?><div align="center"><?if($LOGIN_LINK$)?><a href="$LOGIN_LINK$">Для добавления необходима авторизация</a><?else?>Доступ запрещен<?endif?></div><?else?>
<script type="text/javascript">function reloadChat(){
$('#mchatTd').load(location.href+' #mchatDiv', function(data){
$('input[name="s"]').val($('input[name="s"]', data).val());
});}
function emoticon(code){if (code != ""){var txtarea = document.addform.message;txtarea.focus();if (document.selection) {txtarea.focus();var txtContent = txtarea.value;var str = document.selection.createRange();if (str.text == ""){str.text = code;} else if (txtContent.indexOf(str.text) != -1){str.text = code + str.text;} else {txtarea.value = txtContent + code;}}else{txtarea.value = txtarea.value + code;}}}
$(document).ready(function(){
update=setInterval(reloadChat,60*1000);
/*$('#mchatTd').parent().before('<tr onclick="window.top.scroll(0,0);window.top.$(\'div.news-body:first\').css({ border: \'3px solid red\' });"><td valign="top"><div class="cName" style="font-size:8pt !important;border-bottom: 1px dotted #eeeeee; border-left: 1px dotted #eeeeee; padding-bottom: 5px; padding-top: 5px; background: #ffffff;"><a class="user" href="javascript://">Объявление</a>: <span style="color: green; font-weight: bold; cursor: pointer;">Читаем новости сайта!</span></div></td></tr>');*/
});
</script>
<table border="0" cellpadding="1" cellspacing="1" width="100%">
<tr><td>$FLD_AUTOUPD$</td>
<td width="70%" align="right">
<a href="$RELOAD_URI$" title="Обновить"><img alt="" border="0" align="absmiddle" src="http://trek3r.do.am/bbcodes/accept.png"></a>
<?if($SMILES_URI$)?> <a href="$SMILES_URI$" title="Вставить смайл"><img alt="" border="0" align="absmiddle" src="http://trek3r.do.am/bbcodes/emoticon_smile.png" width=""></a><?endif?>
<?if($BBCODES_URI$)?> <a href="$BBCODES_URI$" title="BB-Коды"><img alt="" border="0" align="absmiddle" src="http://trek3r.do.am/bbcodes/help.png"></a><?endif?>
<?if($MSGCTRL_URI$)?> <a href="$MSGCTRL_URI$" title="Управление сообщениями"><img alt="" border="0" align="absmiddle" src="http://trek3r.do.am/bbcodes/keyboard.png"></a><?endif?>
</td></tr></table>
<?if(!$USER_LOGGED_IN$)?>
<table border="0" cellpadding="1" cellspacing="1" width="100%">
<tr><td colspan="2">$FLD_NAME$</td></tr>
<tr><td width="50%">$FLD_EMAIL$</td><td>$FLD_URL$</td></tr>
</table>
<?endif?>
<?if($FLD_CUSTOM1$ || $FLD_CUSTOM2$)?>
<table border="0" cellpadding="1" cellspacing="1" width="100%">
<tr><td width="50%">$FLD_CUSTOM1$</td><td>$FLD_CUSTOM2$</td></tr>
</table>
<?endif?>
<?if($FLD_SECURE$)?>
<table border="0" cellpadding="1" cellspacing="1" width="100%">
<tr><td width="50%">$FLD_SECURE$</td><td align="left">$IMG_SECURE$</td></tr>
</table>
<?endif?>
<div style="font-size:10px;" align="right">$LENGTH_COUNTER$</div>
<table border="0" cellpadding="1" cellspacing="1" width="100%">
<tr><td width="100%" rowspan="2">$FLD_MESSAGE$ <p><center><div><input type="submit" value="Добавить" class="searchSbmFl" style="margin:0px ;width:100" id="mchatBtn"><div id="mchatAjax" style="display:none"><div class="uploadIMG"></div></div></td></tr></table>
<?endif?></center></a></td></tr></table>