Hi Antoine,
Please add this code on your CUSTOM JS:
(function($){
var tabnav = location.href.split("#tab-").slice(-1)[0];
if ( tabnav || tabnav != '' ) {
$( document ).ready ( function() {
console.log(tabnav);
var navbar = $('.x-navbar').outerHeight();
$('.x-nav-tabs .x-nav-tabs-item').removeClass('active');
$('.x-nav-tabs .x-nav-tabs-item [data-cs-tab-toggle="' + tabnav + '"]').parent('.x-nav-tabs-item').addClass('active');
$('.x-tab-content .x-tab-pane').removeClass('active');
$('.x-tab-content [data-cs-tab-index="' + tabnav + '"]').addClass('active');
setTimeout ( function() { //Let's trigger the scroll animation just after the content is displayed.
var yloc = $('.x-tab-content [data-cs-tab-index="' + tabnav + '"]').offset().top;
console.log($('.x-tab-content [data-cs-tab-index="' + tabnav + '"]').offset().top);
console.log('tab: ' + tabnav + ', yloc: ' + yloc);
$('html, body').animate({
scrollTop: yloc
}, 850, 'easeInOutExpo');
}, 750 );
});
}
})(jQuery);
Then to access the specific tab, add #tab-1, #tab-2 or #tab-3 on the link. For example, if we will access tab 2 of this page: https://e-marketingmix.com/referencement-et-contenu-web/abonnement-bulletin-de-sante-seo, the href value of the button from another page would be:
https://e-marketingmix.com/referencement-et-contenu-web/abonnement-bulletin-de-sante-seo/#tab-2
Hope this helps.