The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
||||
|
||||
![]()
Hello everyone,
Recently we've decided to implement Google Ads in our forums and, as a first step, we used this hack - https://vborg.vbsupport.ru/showthread.php?t=222389 Now, instead of [maxposts] == 1 we used 2, so the ad will always be displayed in the second reply on the page. However, there's a "snag" with the Quote BBCode, as seen in attachment #1: The problem is represented by the quote table width, which by default is 100%. If we were to change this to, say, 76%, the issue would be solved - see attachment #2. The second "however" comes from the fact that we don't want to globally change the Quote BB Code, just for the second reply on every page. To that end, we went to Admin CP -> Styles & Templates -> Style Manager -> ? ? -> BB Code Layout Templates -> bbcode_quote And tried to use the following conditional for the main table: HTML Code:
<if condition="$post['postcount'] % $vboptions['maxposts'] == 2"> <table cellpadding="$stylevar[cellpadding]" cellspacing="0" border="0" width="76%"> <else /> <table cellpadding="$stylevar[cellpadding]" cellspacing="0" border="0" width="100%"> </if> ![]() So, the two main questions are: 1. Can vBulletin conditionals even be used in BB Code templates? 2. If so / not, is there any way to overcome this problem? ![]() |
#2
|
||||
|
||||
![]()
I don't know if conditions can be used in bbcode. The thing is, if you are caching the posts, then I think the bbcode is already parsed in the cached post and so a condition won't work.
Also, setting it to 76% may make it work on *your* browser, set at the width *you* have it set at, but it won't necessarily work on all browsers. I don't know that modificaiton, but maybe you can do something to the image code to make the text wrap around it instead? |
![]() |
Thread Tools | |
Display Modes | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|