
Untitled
By: a guest on
May 2nd, 2012 | syntax:
None | size: 0.94 KB | hits: 35 | expires: Never
jquery mobile device orientation change not resizing text area
.message-entry{
margin-left:10px;
margin-right:0;
margin-bottom:-20px;
}
<footer data-role="footer" id="footer" data-theme="b" data-position="fixed">
<label class="label-message-entry" for="chatMessageEntry">Enter a message:</label>
<textarea rows="8" name="textarea" class="message-entry" id="chatMessageEntry"></textarea>
<a id="chatReplyButton" class="reply-button" data-role="button" data-icon="plus">Reply</a>
</footer> <!--end footer-->
$(window).bind( 'orientationchange', function(e){
var newWidth = $(window).width();
$('.message-entry').css({'width':newWidth + 'px'});
});
@media all and (max-width: 480px) and (min-width: 321px){
.message-entry{
min-width:470px;
}
}
@media all and (max-width: 320px){
.message-entry{
min-width:310px;
}
}