javascript - How to make button appear at bottom of div on hover -
I am trying to add an effect to a site. I have a list of icons that are arranged in 2 groups of 3, which is made using a combination of boot slips-SM-4 using a set minimum-height of 6 squares total.
What am I trying to do when the user enters on any part of the div, this icon changes the image, and the visible creates the button below
before me Both of those features are working from the same, but to change the icon you have to be curved on the icon, and to see the button, you can see the html CSS I am trying to do this without javascript, but if Javascript is the only option, then I would gladly use JS. If someone has done something like this, I would love to hear about it! Thanks for the help. HTML CSS Jquery Not tested, but pretty sure what to do for you. Of course this will only work for a button and icon set. It will need more information to work with several div, icons and hidden buttons. & lt; P & gt; tags I'm looking for a way to change my state on moving them on my specific div.
& lt; div class = "col-sm-4 info-item" & gt; & Lt; A href = "#" & gt; & Lt; img src = "../ desktop / icon1.png" onosauover = "it src = '.. / desktop / icon 1_read.png' 'on-houseout =" this src =' ../desktop/icon1.png & lt; bell & gt; & lt; div class = "icon-text" & gt; & lt; p & gt; increase your conversion rates, thereby increasing profit and customer acquisition. & lt; / P & gt; & lt; / div & gt; & lt; / a & gt; & lt; div class = "hidden-button" & gt; one type = "button" href = "#" class = "BTN BTN-Infection"> I class = "FA-FA-Plus-Circle FA-1X">
.info {padding: 100px;} .info-item {min-height: 350px! Important;} .info-item one {text-decoration: none! Important;} .info-item p {color: black! Important;} # hidden button i {color: red;} # hidden button a {text} -Security: none! Important;} .btn-infection {padding: 20px 10px; text-decoration: none; border color: # ef4035; boundary-radius: 3px; Font-size: 12px; Font weight: 700; color white! Important; Background color: # E9241D; }. Hidden Button A {Visibility: Hidden! Important; }. Hidden Button: A Visibility: Visible: Important; }
& lt; div class = "col-sm-4 info-item" & gt; & Lt; A href = "#" & gt; & Lt; Img class = "change icon" src = "desktop / icon 1 page" & gt; & Lt; Hour & gt; & Lt; Div class = "icon-text" & gt; & Lt; P & gt; Increase your conversion rates, thereby increasing profit and customer acquisition. & Lt; / P & gt; & Lt; / Div & gt; & Lt; / A & gt; & Lt; Div class = "hidden-button" & gt; & Lt; One type = "button" href = "#" class = "btn btn-infection" & gt; & Lt; I class = "fa-fa-plus-circle fa-1x" & gt; & Lt; / I & gt; & Lt; Span & gt; Learn more & lt; / Span & gt; & Lt; / A & gt; & Lt; / Div & gt; & Lt; / Div & gt;
.info {padding: 100px; } .info-item {min-height: 350px! Important; } .info-item one {text-decoration: none! Important; } .info-item p {color: black! Important; } #hidden button i {color: red; } # Hidden button a {text-decoration: none! Important; } .btn-infection {padding: 20px 10px; Text-decoration: None; Border color: # ef4035; Boundary-radius: 3px; Font-size: 12px; Font weight: 700; color white! Important; Background color: # E9241D; } .hidden-button {display: none; }
$ (document) .ready (function () {$ ('.col-sm-4 ') .mouseenter (function () {$ (' .conconchange '). attr (' src ',' /desktop/icon1_red.png ') $ (' hidden-button '). Show ();}) .mouseleave ( Function () {$ ('.conconchange'). Attr ('src', '/desktop/icon1.png') $ ('hidden-button'). Hide ();});});
Comments
Post a Comment