HTML5 Search Input: No Background Image in Chrome?
Posted
by Jason
on Stack Overflow
See other posts from Stack Overflow
or by Jason
Published on 2010-06-07T18:51:04Z
Indexed on
2010/06/07
18:52 UTC
Read the original article
Hit count: 165
I have been pulling my hair out trying to get Chrome to style my search
input with a background image. Firefox has no problem, but I fear it's because it treats the input as a regular text input. Is this simply not possible?
Try this as a demo:
<input type="search" />
?input[type="search"] {
background: transparent
url(http://google.com/intl/en_ALL/images/srpr/logo1w.png) no-repeat 0 0;
}??????
If it worked correctly, it should put Google's logo (or part of it) as the background image for the "Search" input. But as you will see when you look at this in Chrome, it DOES NOT WORK. Any ideas, or is this just one of HTML5's quirks? :\
© Stack Overflow or respective owner