Форма добавления сообщения в мини - чат в самый низ.
Код
<?ifnot($USER_AGENT$='ie')?><br><progress id='jeuwu27' value="0" max="$MAX_MESSAGE_LEN$" simv_left="Осталось $MAX_MESSAGE_LEN$ символов" style="margin-top:-10px;width:100%;height:15px;"></progress>
<script>$('#mchatBtn').css('height','62px');$('#mchatMsgF').css('height','60px');
function countMessLength(){
var rstz = $('#mchatMsgF').val().length;if (rstz<0){rstz=0;$('#mchatMsgF').val($('#mchatMsgF').val().substr(0,$MAX_MESSAGE_LEN$));}$('#jeuwu27').attr('value',rstz)
var rst = $MAX_MESSAGE_LEN$-$('#mchatMsgF').val().length;if (rst<0){rst=0;$('#mchatMsgF').val($('#mchatMsgF').val().substr(0,$MAX_MESSAGE_LEN$));}$('#jeuwu28').html(rst);$('#jeuwu27').attr('simv_left','Осталось '+rst+' символов')
if(rst<=50){$('#mchatMsgF').removeClass('yellow').addClass('red')}
else if(rst>50&&rst<=150){$('#mchatMsgF').removeClass('red').addClass('yellow')}
else if(rst>150){$('#mchatMsgF').removeClass('yellow').removeClass('red')}
}
</script><?endif?>
В CSS:
Код
.red{background:rgba(255, 50, 50, 0.2)}
.yellow{background:rgba(255, 216, 0, 0.3)}