Button With Image Zoom On Hover
How do I make an button with image zoom on hover?
Simple buttons that zoom in on the photo nested within a link. Also has a basic overlay effect for the text to help separate it from the background and keep it readable.. What is a button with image zoom on hover? How do you make a button with image zoom on hover? This script and codes were developed by Chris Steurer on 08 December 2022, Thursday.
Button With Image Zoom On Hover - Script Codes HTML Codes
<!DOCTYPE html>
<html >
<head> <meta charset="UTF-8"> <title>Button With Image Zoom On Hover</title> <link rel="stylesheet" href="css/style.css">
</head>
<body> <div class="twoButtonContainer"> <a href="" class="catImageButton"><div class="buttonText">Shop For <span>DESKS</span></div> <img src="https://cdn1.bigcommerce.com/server800/8c900/product_images/uploaded_images/test-zoom-image.jpg?t=1401392592"> </a>
</div>
<div class="twoButtonContainer"> <a href="" class="catImageButton"><div class="buttonText">Shop For <span>CHAIRS</span></div> <img src="https://cdn1.bigcommerce.com/server800/8c900/product_images/uploaded_images/test-zoom-image2.jpg?t=1401395770"> </a>
</div> <script src='http://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.3/jquery.min.js'></script>
</body>
</html>
Button With Image Zoom On Hover - Script Codes CSS Codes
/* General Styles (Not Needed) */
@import url(https://fonts.googleapis.com/css?family=Roboto:400,300,700);
html { min-height: 100%;
}
body { background: linear-gradient(0deg, #f0efe6, #f2f5ff); font-family: 'Roboto', sans-serif; font-weight: 300;
}
* { -webkit-box-sizing: border-box; -moz-box-sizing: border-box; -ms-box-sizing: border-box; box-sizing: border-box;
}
/*////////////////////////////////// // Button Styles \
//////////////////////////////////*/
/* This is only an extension class (not used in HTML) to control global animation timing */
.animationControl, a.catImageButton, a.catImageButton span, a.catImageButton img, a.catImageButton .buttonText { -webkit-transition: all 1s ease; -moz-transition: all 1s ease; -o-transition: all 1s ease; -ms-transition: all 1s ease; transition: all 1s ease;
}
/* Button Container Layout */
.twoButtonContainer { width: 50%; min-width: 190px; float: left; /* Not Needed (simply places the container nearer the center of the page for display purposes only) */ margin-top: 15vh;
}
/* Normal State */
a.catImageButton { display: block; text-decoration: none; height: 75px; width: 180px; border: solid 2px #dbdbdb; margin: 0 auto; color: #efefef; overflow: hidden;
}
a.catImageButton span { display: block; font-size: 2em; line-height: 0.8em; color: #fff;
}
a.catImageButton img { height: 75px; width: 176px; -webkit-filter: blur(1px); -moz-filter: blur(1px); -o-filter: blur(1px); -ms-filter: blur(1px); filter: blur(1px); position: relative; top: -95px;
}
a.catImageButton .buttonText { height: 95px; width: 182px; padding: 10px 0 10px 0; position: relative; z-index: 10; right: 5px; background: rgba(0, 0, 0, 0.2); text-align: center;
}
/* Button Hover State */
a.catImageButton:hover { border: solid 2px #666;
}
a.catImageButton:hover img { /* The height and width are what control the zoom effect. Set to a larger size to zoom further, smaller size to zoom out */ height: 95px; width: 224px; /* Unblur the image */ -webkit-filter: blur(0px); -moz-filter: blur(0px); -o-filter: blur(0px); -ms-filter: blur(0px); filter: blur(0px);
}
/* Fade out the text on hover to get a better view of the image */
a.catImageButton:hover .buttonText,
a.catImageButton:hover .buttonText span { color: rgba(255, 255, 255, 0.2);
}
Developer | Chris Steurer |
Username | stoypenny |
Uploaded | December 08, 2022 |
Rating | 3 |
Size | 3,642 Kb |
Views | 12,144 |
Find the perfect freelance services for your business! Fiverr's mission is to change how the world works together. Fiverr connects businesses with freelancers offering digital services in 500+ categories. Find Developer!
Name | Size |
Vertical WooCommerce jQuery Menu with Subcategories | 2,895 Kb |
Remove Empty WooCommerce Filters | 2,583 Kb |
Button Hover Effects | 1,993 Kb |
Simple CSS Progress Bars | 3,021 Kb |
CSS3 Image Filters Template | 3,025 Kb |
Responsive Menu | 2,466 Kb |
Simple jQuery Text Spoiler Reveal | 1,913 Kb |
Elegent Slide Up Modal Forms | 3,820 Kb |
Simple Contact Cards | 2,985 Kb |
Basic Lightbox | 2,166 Kb |
Jasper is the AI Content Generator that helps you and your team break through creative blocks to create amazing, original content 10X faster. Discover all the ways the Jasper AI Content Platform can help streamline your creative workflows. Start For Free!
Name | Username | Size |
CSS Dynamic Width Square Div | Elleestcrimi | 2,861 Kb |
CSS3 Form Page Design | Rssatnam | 3,613 Kb |
Flat design iframe | Damienpm | 1,819 Kb |
Sass random color animation | Jotavejv | 4,827 Kb |
Lightrays v2 | Sinthetyc | 2,903 Kb |
Flat buttons for Eliassen.com | Kdooley89 | 1,737 Kb |
Draggables in pure angular | Rlo206 | 5,167 Kb |
Greyscale image with filter in CSS3 | NickyCDK | 1,562 Kb |
Starfield old school style | Bolloxim | 5,214 Kb |
Slides-07-1 POSITION | Exhtml | 1,909 Kb |
Surf anonymously, prevent hackers from acquiring your IP address, send anonymous email, and encrypt your Internet connection. High speed, ultra secure, and easy to use. Instant setup. Hide Your IP Now!