CSS: Background-Image Not Showing Up -



CSS: Background-Image Not Showing Up -

i'm attempting design , create chatbox ui personal project, i've run problem something...

i have div acts exit button chatbox. have .png want utilize main appearance of element. using css's background: url(), intended background button, doesn't appear showing up.

i looked @ chrome dev tools, said recognized picture... linked properly, , other attributes showing, reason, wasn't appearing:

html:

<div class= "cb"> <div class= "cb-header"> <div class= "cb-buttons"> <div class= "cb-exit"></div> </div> <div class= "cb-name">ajeethen uthayakumaran</div> </div> ... </div>

css:

.cb { background-color: rgb(226, 226, 226); position:absolute; bottom:0; width: 260px; height: 350px; float:right; } .cb-header { background-color: rgb(0, 248, 66); width: 100%; height: 40px; } .cb-name { display:inline-block; width: 195px; font-family:oswald; font-size: 16px; color: rgb(0, 112, 38); padding: 7px 10px 4px; } .cb-buttons { display:inline-block; float:right; } .cb-exit { display:inline-block; background: url(../img/exit.png) no-repeat; height: 40px; width: 40px; }

have ideas? if need else besides markup , css, please comment.

update: file path linked correctly... connected properly, , can see via dev tools chrome has provided us...

however, realized image 600 x 600, way bigger intended 40x40... alter anything?

as mentioned @showdev

it works fine, here demo:

http://jsfiddle.net/jlnrv

make sure file path correct!

here brief description of file paths:

./ means current directory

../ means parent of current directory, not root directory

/ root directory

myfile.text in current directory, ./myfile.text

../myfile.text 1 level above , /myfile.text lives in root directory.

css background-image

Comments

Popular posts from this blog

php - Android app custom user registration and login with cookie using facebook sdk -

django - Access session in user model .save() -

php - .htaccess Multiple Rewrite Rules / Prioritizing -