1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

XF 1.5 Board margins and ad placement

Discussion in 'Styling and Customization Questions' started by Huskermax, Jun 24, 2016.

  1. Huskermax

    Huskermax Member

    So I am in the process of transferring from VB to XenForo and I am trying to get my ads placed right on the XenForo test board I set up before I go live with it. See Screen shots.

    So I need to fix the margins so the ad is not covering anything and fits in that right side.

    This is a screen shot of our VB board. I need to know how to places these right side ads in to the XenForo templates in that right margin before I do the transfer.
  2. Huskermax

    Huskermax Member

    Here is the code for the ad in the 1st screen shot or top right corner below navbar.

    This is copied right out from the ad_sidebar_top template.

    <xen:hook name="ad_sidebar_top" />
    <!-- HM Forum 300 Top [async] -->
    <script type="text/javascript">if (!window.AdButler){(function(){var s = document.createElement("script"); s.async = true; s.type = "text/javascript";s.src = 'http://ab166223.adbutler-exciton.com/app.js';var n = document.getElementsByTagName("script")[0]; n.parentNode.insertBefore(s, n);}());}</script>
    <script type="text/javascript">
    var AdButler = AdButler || {}; AdButler.ads = AdButler.ads || [];
    var abkw = window.abkw || '';
    var plc177460 = window.plc177460 || 0;
    document.write('<'+'div id="placement_177460_'+plc177460+'"></'+'div>');
    AdButler.ads.push({handler: function(opt){ AdButler.register(166223, 177460, [300,250], 'placement_177460_'+opt.place, opt); }, opt: { place: plc177460++, keywords: abkw, domain: 'ab166223.adbutler-exciton.com', click:'CLICK_MACRO_PLACEHOLDER' }});
  3. Huskermax

    Huskermax Member

    As far as the 1st screen shot goes I have not been able to fix that ad so it sits inside the margins of the board. I have been messing with:

    Responsive Design and Page Width Controller

    I still can't get it to sit inside the board. It floats over the margin every time. Do I need add more code in the ad code?
  4. woody

    woody Active Member

    Sidebar: increase width to 300px
  5. Huskermax

    Huskermax Member

    That worked to get it to fit on the side. What about the header or navbar. Now the ad is covering the search bar. I need to increase that space between the top of the forum boards and the bottom of the navbar.


    See ad over search bar at link.
    Last edited: Jun 27, 2016
  6. woody

    woody Active Member

    wrap your ad code in a style, and use margin-top
  7. Huskermax

    Huskermax Member

    I am not sure how to do this? the ad code is above can you help me with that?
  8. Huskermax

    Huskermax Member

    <div style="text-align: center; margin-top:8px;">

    I got and it works. Thanks!

Share This Page