How do I change the color of the text cursor in an input field in IE?
The color of the text cursor in an input on IE is always the inverse of the background color. So you can't on IE.
This is also unspecced by W3C so don't expect support to be anywhere, if there is, then it's merely an artifact :-)
Edit: 9-years later and we now have caret-color
, but not for IE or Edge. Works on other browsers.
How to change cursor color without changing text color?
You can make a custom one.
input, textarea {
cursor: url(cursor.cur);
}
How to change background-color of a li if I put the cursor in an input field inside the li?
You can't do this with pure css, you'll need to use javascript / jQuery:
$("input[type='text']").focus(function(){
$("li").removeClass("background");
$(this).closest("li").addClass("background");
});
See: http://jsfiddle.net/HF5Tx/
Related Topics
Ie9 + CSS: Problem with Fixed Header Table
No Possibility to Select Text Inside <Input> When Parent Is Draggable
How to Make Border Radius in Popup Chrome Extension
Z-Index and Relative/Absolute Positioning
Google Fonts External CSS Vs Copying The Code of External CSS in My CSS
Unexpected Empty Space Using Flexbox
CSS Dropdown Menu Hidden Behind Content Ie7
How to Make Rotated Elements in a Flexbox Fixed to The Right Side of a Page
Changing Rotation of Mat Expansion Indicator
Vertically Aligning an Image to The Bottom Inside a Bootstrap "Column"
Cannot Stretch Svg Background Image, Aspect Ratio Will Be Preserved
Horizontal Sharp Background Gradient with Specific Length of First Color
Django 1.8 Static Files Doesnt Work
Only CSS Rotate Box-Shadow Without Original Element