html - How to make 3 images stay in the same line responsive and hover effect -


i using template make website , not @ css. have 3 images want stay in same line, have hover effect , fit screen different resolutions.

i found bits of want on internet never fit them results.

from know hover effect doesn't work on mobile devices think should use 2 css. 1 mobile , 1 computers , tablets. when resolution <300 no hover. else hover.

please correct me if wrong. images have no other formats, code <img src="">.

i don't think you'll want have different stylesheets, since should able in nice responsive single css file.

this should started. you'll want add classes these on proper site class='inline-image' or similar.

html

<div>     <img src='http://upload.wikimedia.org/wikipedia/commons/a/a9/example.jpg' />     <img src='http://upload.wikimedia.org/wikipedia/commons/a/a9/example.jpg' />     <img src='http://upload.wikimedia.org/wikipedia/commons/a/a9/example.jpg' /> </div> 

stylesheet

div {     /* keep images on 1 line*/     white-space: nowrap; }  img {     background-color: #ffffff;     padding: 10px; }  img:hover {     background-color: #000000; } 

jsfiddle: http://jsfiddle.net/cvsvh/


Comments

Popular posts from this blog

android - Get AccessToken using signpost OAuth without opening a browser (Two legged Oauth) -

org.mockito.exceptions.misusing.InvalidUseOfMatchersException: mockito -

google shop client API returns 400 bad request error while adding an item -