Код: Выделить всё
#smiley-box {
width: 18%;
float: right;
}
Код: Выделить всё
#smiley-box {
width: 18%;
float: right;
}
Код: Выделить всё
<div class="panel">
Код: Выделить всё
<div class="panel smiley-posting">
Код: Выделить всё
#smiley-box, .smiley-posting {
height: 300px;
overflow: auto;
}
#smiley-box,
можно удалить.Код: Выделить всё
<script type="text/javascript">
$(function() {
var txt = $('#message-box textarea'),
sBlock = $('#smiley-box').css({
'max-height': '355px',
'min-height': txt.height()+'px',
'height': txt.height()+'px',
'overflow-x': 'auto'
}).append('<div class="smiles-div" style="display: none;" />'),
hdBlock = $('.smiles-div'),
content = null,
height = txt.height();
txt.bind('keyup', function() {
content = txt.val();
content = content.replace(/\n/g, '<br>');
hdBlock.html(content);
sBlock.css('height', hdBlock.height());
});
});
</script>