Simple filtering by html5 targets.
How do I make an simple filtering by html5 targets.?
What is a simple filtering by html5 targets.? How do you make a simple filtering by html5 targets.? This script and codes were developed by Orrin Ward on 01 February 2023, Wednesday.
Simple filtering by html5 targets. - Script Codes HTML Codes
<!DOCTYPE html>
<html >
<head> <meta charset="UTF-8"> <title>Simple filtering by html5 targets.</title> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/normalize/5.0.0/normalize.min.css"> <link rel="stylesheet" href="css/style.css">
</head>
<body> <div class='filters'> <a data-target='item'>All</a> <a data-target='red-thing'>Red</a> <a data-target='blue-thing'>Blue</a> <a data-target='green-thing'>Green</a>
</div>
<div class='container'> <div class='item red-thing'></div> <div class='item blue-thing'></div> <div class='item green-thing'></div> <div class='item blue-thing'></div> <div class='item green-thing'></div> <div class='item red-thing'></div> <div class='item red-thing'></div> <div class='item blue-thing'></div> <div class='item green-thing'></div>
</div> <script src='http://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.3/jquery.min.js'></script> <script src="js/index.js"></script>
</body>
</html>
Simple filtering by html5 targets. - Script Codes CSS Codes
.filters { margin: 20px;
}
a { padding: 4px; background: #DDD;
}
a:hover { cursor: pointer; cursor: hand;
}
.container .item { width: 200px; height: 200px; margin: 10px; float: left;
}
.container .item.blue-thing { background: blue;
}
.container .item.green-thing { background: green;
}
.container .item.red-thing { background: red;
}
Simple filtering by html5 targets. - Script Codes JS Codes
$(".filters a").on("click", function(){ filter_option = "." + $(this).attr("data-target").toString(); $('.item').not(filter_option).fadeTo(300,0.1); $(filter_option).fadeTo(300,1);
})
Developer | Orrin Ward |
Username | orrinward |
Uploaded | February 01, 2023 |
Rating | 3 |
Size | 2,426 Kb |
Views | 4,048 |
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 |
Super Discount | 3,225 Kb |
A Pen by Orrin Ward | 15,134 Kb |
Price Comparison Table | 3,459 Kb |
Virtual Freshers Fair Layout | 9,349 Kb |
Leemail change delivery confim | 3,100 Kb |
Bootstrap form HAML | 6,119 Kb |
Expandable block items. | 2,923 Kb |
Leemail footer play | 0 Kb |
AfG App launcher slug SCSS | 2,262 Kb |
SMR2013 hack | 18,853 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 |
Wikipedia viewer | Chpecson | 2,865 Kb |
Client-side Email Validation | Collizo4sky | 1,538 Kb |
CSS background-size - GSAP | Jonathan | 2,209 Kb |
Custom checkbox example | Capelo | 3,495 Kb |
The CodePen Logo | Kindofone | 4,259 Kb |
Progressively reveal dots on a Bezier curve | GreenSock | 2,489 Kb |
SlideupBoxes | Gavra | 23,772 Kb |
CSS Heart Loaders | Nourabusoud | 2,161 Kb |
Arrow Navigation | Hinducows | 1,973 Kb |
SVG Basics | HipsterBrown | 1,852 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!