-
AuthorPosts
-
March 17, 2021 at 12:55 pm #1288722
Good morning,
referring to this topic: https://kriesi.at/support/topic/download-link-in-tab-section-tab-title/
i was able to force a download action after clicking on a tab section, thanks to the following script provided by Ismael:<script>
(function($){
function a() {
var download = $(‘.av-section-tab-title[data-av-tab-section-title=”7″]’);download.on(‘click’, function(e) {
e.preventDefault();
window.open(
‘YOUR LINK’,
‘_blank’
);
});
}a();
})(jQuery);
</script>Unfortunately the above script is no longer working. May it be due to the new theme updates? I’m kindly asking if it would be possible to fix the code to make it work again.
Thank you very much
March 21, 2021 at 7:56 am #1289392Hey Qgrafica_7,
Could you post a link to where we can see the element where you are trying to apply this to please?
Best regards,
RikardMarch 22, 2021 at 3:08 pm #1289641Hi, thank you for your reply. I’ve included the link in the private section. Scroll down just a little on the page and you’ll find the tab section. The last item on the right is the “download” button i’m asking about
March 25, 2021 at 10:04 am #1290334Hi,
Thanks for that. It looks like you have added another tab since adding the script? The download tab now has a different number, please try the following instead:
<script> (function($){ function a() { var download = $('.av-section-tab-title[data-av-tab-section-title="8"]'); download.on('click', function(e) { e.preventDefault(); window.open( 'YOUR LINK', '_blank' ); }); } a(); })(jQuery); </script>Best regards,
RikardMarch 25, 2021 at 11:09 am #1290344Good morning,
i tried and the provided code still doesn’t workMarch 29, 2021 at 6:40 am #1291020 -
AuthorPosts
- You must be logged in to reply to this topic.
