Reputation: 1
I am having problems with textarea and input type text in ios devices. The bottom part of the text gets cuts off. How can i fix the text so it is displayed fully ?
Here is the css:
textarea {
width: 97%;
padding: 5px 1.5%;
height: 70px;
line-height: 150%;
border: 1px solid #ccc;
}
Upvotes: 0
Views: 1700
Reputation: 130
Can you try this one. I tested it on iPhone as well and it will work fine. Please check it at your site.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name = "viewport" content = "initial-scale = 2.3, user-scalable = no">
<title>Untitled Document</title>
<style>
body {
width: 100%;
}
textarea {
width: 97%;
padding: 5px 0.5%;
height: 5em;
line-height: 1.5em;
border: 1px solid #ccc;
}
</style>
</head>
<body>
<textarea>
</textarea>
</body>
</html>
Upvotes: 0
Reputation: 86
Define the height in "em", no "px" ... Pixels tell the browser the textarea height should be 70px, in EMs you tell the browser the height should be 5 rows for example (height: 5em;).
Upvotes: 1