Select Page

Currently my Blog Module displays: Author | Date | Category | Comment Count

I wanted to add a link to my affiliate disclosure at the end of that post meta data so that it would read: Author | Date | Category | Comment Count | This post may contain affiliate links

When not using the Divi Theme Builder, I had previously been able to accomplish this on other Divi sites by editing the single.php file in my child theme. However that was not working in this instance since I was now using their Theme Builder. So I reached out to Elegant Themes support for help and they sent me this code which works like a charm.

Add this code to your Divi –> Theme Options –> Integration into the <head> section:

<script>
   jQuery(document).ready(function(){
    jQuery('.comments-number').append(" | Link text goes here");
	   $(".comments-number").wrap('<a href="https://example.com" />');
  });
</script>

Obviously replace the “Link text goes here” with whatever you want it to say and the “example.com” with your URL. Here's how it looks in action on my site: