Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums JavaScript Toggle between images. Reply To: Toggle between images.

#249746
Paulie_D
Member

Firstly, it’s not really clear what these two buttons are doing and why you are toggling them

Frankly, in my opinion, you’re going about this the wrong way.

Firstly, divs are not buttons

See – http://www.karlgroves.com/2013/05/14/links-are-not-buttons-neither-are-divs-and-spans/

Secondly, since these are styling images, they shouldn’t be inline…they should be background-images and in the CSS.

http://codepen.io/Paulie-D/pen/pRJjzV