Here’s a quick tip on how to open the Divi Fullwidth Header module’s first button (Button #1) in a new tab.
Navigate to the Divi Theme Options screen and then choose the Integration tab and add the following code to the <head> section:
Now make sure you’ve enabled the header code section by toggling the Enable Header Code button to on. This is a bit of a mystery to me as mine says Enable and if I switch to Disable, it doesn’t work. In my mind you need to click Enable to enable but obviously not. If the button doesn’t open the link in a new tab, replace all the inverted commas and quotation marks in the code above.
This post in a slight variation on the post Open Divi call to action in a new tab by divithemeexamples.com which is unfortunately no longer available.
worked for me! Thank you!
Worked great, thanks!
This works well, but is there a way to apply to only a specific Full Width Header – the above code applies to all.
Thanks in advance
Hi James,
If you want it to work on a specific page, you could place a Code Module on the page in question and add the script to that.
I know this is old, but I needed it today. To target a specific module, you can add an ID to your module and then just put that into the code.
jQuery(document).ready(function(){
jQuery(“#YOURID .et_pb_more_button.et_pb_button.et_pb_button_one”).attr(‘target’, ‘_blank’);});
That worked for me anyway.
THANK YOU a thousand times!! You just saved me so much time and headache! Love it when I find a quick solution that works 🙂
Hey Rob! Thank you for this. Do you know how to cause the Text Title link to open in a new window as well? I’m doing this for the fullwidth slider module and all is well with the button link, but I’m now trying to apply to the title link as well, as it seems to be a separate function…Any thoughts, ideas welcome!! Paul
Thank you! Tried a different solution that did not work – this is perfect!!!