Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #425637

    Hi, I want to add the outbrain code manually so it will only show on blog posts below the “share this entry”. I tried adding it in the single.php file but it broke the theme so I figured you would know better :)

    #425750

    Hey DROR!

    Thank you for using Enfold.

    I’m not sure what’s the purpose of the code but if you want it to display right before the “Share Section” of the posts, maybe you can edit includes > loop-index.php. Add the code right after line 200:

    echo $content;
    

    Use this:

    echo '<div class="OUTBRAIN" data-widget-id="NA"></div>';
    

    Add this to the functions.php file:

    add_action('wp_head', 'ava_outbrain_mod', 10);
    function ava_outbrain_mod() {
    echo '<script type="text/javascript" async="async" src="http://widgets.outbrain.com/outbrain.js "></script>';
    }

    I tried to install it but it’s not working. I got an error with the widget. Please contact the plugin author for more info.

    Regards,
    Ismael

    #426439

    Hi, it does actually seem to work but I want it to show after the share buttons and above the comments section. Where should I add the code in order to do this?

    #426835

    Hi!

    Try putting it before line 41 in single.php:

    comments_template();
    

    Regards,
    Josue

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.