I'm basically creating a filter button. If I press button1 {this will happen} If press button2 {this will happen}
but if I press button1 and then button2 {this has to happen}
This is the code I have so far. Thanks!
$(document).ready(function() {
if($('#button1').click(function() && $('#button2').click(function()){
//perform actions
});
Here is the logic
button 1 handler {
set var to indicate click
do what you need
}
button 2 handler {
check var to see if button 1 is clicked
do whatever you need based on the var check
}
This only handles button 1 click followed by 2, but you get the idea and should be able to figure out if button 2 is clicked then 1
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With