The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
||||
|
||||
Help needed with some conditionals (forum/first post)
I need to show a customized postibit_lagacy template in some forums. And this should apply only to the first post of the threads.
So, I founded these conditionals: Code:
<if condition="in_array($thread['forumid'], array(1,2,3,6))"></if> Code:
<if condition="!$GLOBALS['FIRSTPOSTID']"></if> Should I do something like this? Code:
<if condition="!$GLOBALS['FIRSTPOSTID']" AND in_array($thread['forumid'], array(1,2,3,6))"> My custom postbit_legacy code. <else /> Original postbit_legacy code. </if> |
#2
|
|||
|
|||
<if condition="!$GLOBALS['FIRSTPOSTID']" AND in_array($thread['forumid'], array(1,2,3,6))">
That double quote has to be removed. |
Благодарность от: | ||
TheLastSuperman |
#3
|
||||
|
||||
Yes, I already founded it! Thanks!
--------------- Added 31 Oct 2015 at 17:35 --------------- I have a problem: using those conditionals, when I add another message, it first show me the new postbit_legacy that I edited. I have to reload the page in order to see the reply using the old postbit_legacy code. Some suggestions? edit: SOLVED. --------------- Added 31 Oct 2015 at 18:44 --------------- I have another question. Is there a variable to show the Forum(Section) Title in postbit_legacy? I tried this: $foruminfo[title] and this: $foruminfo[title_clean] but it doesn't work. |
#4
|
||||
|
||||
Quote:
HTML Code:
$forum[title] |
2 благодарности(ей) от: | ||
TheLastSuperman, Triky |
#5
|
||||
|
||||
Thank you, now it works perfectly!
|
Благодарность от: | ||
TheLastSuperman |
#6
|
|||
|
|||
You may be able to accomplish your customization using CSS. Here is some code that I put in the postbit to change the class of first posts:
HTML Code:
<table id="post$post[postid]" class="<if condition="$post[parentid]==0 AND $forum[forumid] != 4">postbit_first<else />postbit</if>">
|
Благодарность от: | ||
Triky |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|