Last active
February 7, 2025 01:20
-
-
Save dantetesta/db8098f497e2acd4834363d84508c4f2 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*By: Jarvis e Dante*/ | |
/* Tab que abre ao clicar no link*/ | |
/* Defina no HREF dos links os ids das tabs = #tab1, #tab2, #tab3 */ | |
/* Defina nas colunas/secoes onde será posto os conteudos o ids das tabs = #tab1, #tab2, #tab3 e em todos eles a classe .tab */ | |
<script> | |
jQuery(document).ready(function(){ | |
jQuery('#tab1').css('display','block'); | |
jQuery(".link a").click(function(){ | |
var id = jQuery(this).attr("href"); | |
jQuery('.tab:not('+id+')').css('display','none'); | |
jQuery(id).css('display','block'); | |
}); | |
}); | |
</script> | |
<style> | |
.tab{ | |
display: none; | |
} | |
</style> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment