Make textarea height 100% of container [closed] - html

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 10 years ago.
I have a textarea where I'd like the height to be the same of the container.
I've tried using height: 100%; although it doesn't seem to be working.
Does anybody know why?

Could you post some of your code? Could be anything. If you try the basics, it should work for all browsers.
.container {
border: 1px solid #000000;
height: 300px;
}
.container textarea{
border: 1px solid red;
height: 100%;
}
<div class="container">
<textarea>Hello world!</textarea>
</div>
Here you have an example: Textarea

Related

There is a very large blank space on my website [closed]

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 10 years ago.
Here is the website of question: http://keyclub.paschalcs.org/about/
Does anyone know why there is that large block of white there opposed to on the home page...?
If you are talking about the whitespace before the navigation
CSS Fix:
#page #pagehold {
width: 954px;
margin-top: 120px;
}
Screenshot after fix:
you are giving more margin that's what the gap is coming:
replace this code:
#page #pageHold {
margin-top: 120px;
width: 954px;
}
Try this
#page #pageHold {
margin-top: 120px;
width: 954px;
}
you put some extra margin on the top of you page holder div

Hover to href img src? [closed]

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 10 years ago.
Hey i have been trying this for a while but with no luck.
I have the following code:
<img src="image link">
How can i apply an image hover to the img src? Thanks
Example of using background image instead of an <img> tag.
<a href="...." rel="fancybox"><a>
CSS:
a[rel=fancybox] {
display: block;
background: url('image1.jpg') no-repeat 0 0 transparent;
width: 100px;
height: 100px;
}
a[rel=...]:hover {
background: url('image2.jpg') no-repeat 0 0 transparent;
}
You may need to preload your images.
using JS:
<a href="" rel="" onmouseover="this.getElementById('i1').src='/images/image_hover.jpg'" onmouseout="this.getElementById('i1').src='/images/image.jpg'">
<img id="i1" src="/images/image.jpg">
</a>

Adding a grey border to the edge of my website using CSS [closed]

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 10 years ago.
I want to add a border to the edges of my website like this: ( I'm referring to the grey border on the left and right edges of the site)
I'm struggling to complete this with CSS. The one thing I don't understand is how the shadowing is created between the white and the grey.
Can someone help?
Try box-shadow on the container element:
.container {
box-shadow: 0 0 10px 10px #666;
}
Adjust the size (10px), blur (10px) and color (#666) as needed.
That is done with a simple box-shadow. Demo: http://jsbin.com/ivugeh/1/edit
<body>
<div class="page">
</div>
</body>
body {
background: url('http://dovetail-demo.squarespace.com/assets/concrete-texture.png');
padding: 0;
margin: 0;
}
.page {
box-shadow: 0 0 8px 0 rgba(0,0,0,0.2);
background: #fff;
width: 400px;
margin: 0 auto;
height: 100%;
}

Background Image Swap On MouseOver For Unorderd List Items [closed]

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 10 years ago.
I have a list items and I want to have an image on the items instead of a text....
What is the best way to do it? and what is killing me is trying to swap the image with onmouseover event...
Any help would be appreciated....
You can do it like this My Fiddle
Explanation:
Here you give a background image to each <li> element and than you give a little padding to these <li>... now using :hover you replace these with another image :)
HTML
<ul>
<li>Hello</li>
<li>World</li>
</ul>​
CSS
ul li {
background-image: url('http://www.bseindia.com/include/images/nav_bullet.png');
background-repeat: no-repeat;
background-position: 2px 4px;
padding-left: 10px;
}
li:hover {
background-image: url('http://www.rbs.in/India/_image/bullet-blue.gif');
background-repeat: no-repeat;
background-position: 2px 4px;
padding-left: 10px;
}
​

How to print a square using HTML (on a printer)? [closed]

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 11 years ago.
How to print a square precisely with 1 by 1 inch?
I mean, .strong { width: 1in; height: 1in; } won't work! What really goes wrong? How to calculate this error?
edit: everybody talks about screen pixel and the 1/72 ratio. What happens when it goes to the printer?
Well you can try using the in unit in CSS:
.square {
width:1in;
height:1in;
}
Demo: http://jsfiddle.net/w5H5d/
However:
Keep in mind that an inch on screen is not necessarily an actual inch. Even when printing, you simply don't have total control over the output, so I would say this is impossible to do accurately.
Do this:
HTML Markup:
<div id = "square"></div>
CSS:
#square
{
height:1in;width:1in;background-color:black;
}
What about using css and html mixed.
<div class="square"></div>
<div class="square"></div>
<div class="square"></div>
<div class="square"></div>
.square {
border: 1px solid;
width: 1in;
height: 1in;
}
If you're really looking for just a 1" square, using 'only HTML', you're probably going to want to do some inline CSS. Dead simple really.
<div style="width: 1in; height: 1in;"/>
To add color, simply drop the background-color property in:
<div style="width: 1in; height: 1in; background-color: blue;"/>