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

Quotes & Attachments Run Into The Advertisements In First Post

Discussion in 'Styling and Customization Questions' started by TheBigK, Dec 17, 2011.

  1. TheBigK

    TheBigK Well-Known Member

    I've created an ad-spot in every first post, right-aligned with the text; similar to the ad in first post in vBulletin.

    The only issue I'm facing is that if the first post has a quote or attachment, then the quote/attachment container runs into the advertisements. Is there a CSS trick to adjust the size of the quote or attachment container dynamically so that they keep some margin with the advertisements?
     
  2. TheBigK

    TheBigK Well-Known Member

    Sorry for my impatience. Can someone help? I really need some advise as I must get this working in next 12 hours. o_O
     
  3. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    What template code are you using for the ad? What ad template?

    Or if you post a URL showing the problem then I can troubleshoot from there.
     
  4. TheBigK

    TheBigK Well-Known Member

    Thank you, Jake. I used following code in ad_message_body template -

    Code:
    <xen:hook name="ad_message_body" />
    <xen:if is="{$post.position} == 0 AND !{$message.conversation_id}">
    <div style="float: right; padding-left: 5px">
    Ad content here
    </div>
    </xen:if>
    It displays code right aligned with the text in first post. But when the first post has a 'quote', or 'attachment', then the quote holder or code holder (above) extends to the right-boundary, running into the advertisement. The normal text aligns well with the advertisement.

    I don't have access to my test setup at the moment. Will try to upload screenshot in some time.
     
  5. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    No problems here. It must be something with your style. Ideally I need to be able to load the web page so I can work with the problem. Is the test site online?
     
  6. TheBigK

    TheBigK Well-Known Member

    Oh well, I've it on my localhost. I can put it live for some time, if needed. But here's a screenshot -

    quote-runs-into-ad.png
     
  7. TheBigK

    TheBigK Well-Known Member

    I can reproduce the problem on default style, as you can see in the screenshot.
     
  8. TheBigK

    TheBigK Well-Known Member

  9. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    Problem confirmed. Unfortunately I was unable to fix it in my testing. I tried several CSS fixes.
     
  10. TheBigK

    TheBigK Well-Known Member

    Umm, what should I do now? Is there a way to make the attachments and quotes dynamic in width?
     
  11. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    They already are. That's the weird thing. No explicit width is defined.
     
  12. steel_curtain

    steel_curtain Well-Known Member

Share This Page