im having issue with png image as im using it on a input type. . . as a search bar it always shows the background even the image is transparent what should i do?

this is the image shows the background . . . . sorry had to post image like this because it was saying link forbidden.

lookpic.com/c1/i2/2810/Tga5pCQ8.jpeg

*CSS CODE --------

.smartbar ul li input.search_bar {
	border:none;
	width:174px;
	height:22px;
	background-image: url(../images/input_search.png);
	background-repeat: no-repeat;
	padding: 0 5px 0 10px;	
	float:left;
	margin: 0 4px 0 4px;
}

Recommended Answers

All 7 Replies

Member Avatar for iamthwee

Could this be a problem to do with browsers.

I know older browsers don't support transparency?

but im using firefox 4 :)

tried with chrome safari same . . . . thats not browser problem it happens when im using an input type and a png image ? any idea

Try adding background-color:#bee0e1; to your .smartbar ul li input.search_bar css

Try adding background-color:#bee0e1; to your .smartbar ul li input.search_bar css

thanx that solves the problem still the color is in the bg but not showing and it still doesnt answer my question why is the color is in the background and is not transparent?

Hi, it's because input fields automatically have the background colour set to white

i think its a ie related problem

I don't think it's just IE related, it's the same in most browsers

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.