PDA

View Full Version : Work in progress


leejohn02
11-02-2012, 06:59 AM
i am currently trying to adapt a mod to vbulletin 4 but i am running into some difficultly, i am getting the most part working but its not showing the options in the drop down menu

<!-- Subforum pull-down menu --------------------------------------->
<form action="forumdisplay.php" method="get">
<input name="s" value="" type="hidden">
<input name="daysprune" value="-1" type="hidden">
<select name="f" onchange="this.form.submit();">
<if condition="$forum[statusicon] == 'new'">
<option value="$forum[forumid]" style="font-weight:bold;">$forum[title]</option>
<else />
<option value="$forum[forumid]">$forum[title]</option>
</if>
$forum[subforums]
</select>
<input class="button" value="$vbphrase[go]" type="submit">
</form>
<!-- Subforum pull-down menu --------------------------------------->


the problems i am having i have highlighted in red, they only seem to be showing that text in the red and not the actual sub sections, the original code if anyone wishes to develop it themeselves is located here

https://vborg.vbsupport.ru/showthread.php?t=99821

kh99
11-02-2012, 11:40 AM
Try this:

<!-- Subforum pull-down menu --------------------------------------->
<form action="forumdisplay.php" method="get">
<input name="s" value="" type="hidden">
<input name="daysprune" value="-1" type="hidden">
<select name="f" onchange="this.form.submit();">
<vb:if condition="$forum[statusicon] == 'new'">
<option value="{vb:raw forum.forumid}" style="font-weight:bold;">{vb:var forum.title}</option>
<vb:else />
<option value="{vb:raw forum.forumid}">{vb:var forum.title}</option>
</vb:if>
{vb:raw forum.subforums}
</select>
<input class="button" value="{vb:phrase go}" type="submit">
</form>
<!-- Subforum pull-down menu --------------------------------------->

leejohn02
11-03-2012, 06:10 AM
thats great now i just need get the depth of the forums to work the original line

<if condition="$forum[depth] == '2'">
&nbsp; &nbsp;
</if>

doesnt work any ideas??

ForceHSS
11-03-2012, 06:34 AM
not sure if this will help or even what u are looking for

<!-- Subforum pull-down menu --------------------------------------->
<option value="$forum[forumid]">
<if condition="$forum[depth] == '2'">
</if>
<if condition="$forum[depth] == '3'">
</if>
<if condition="$forum[statusicon] == 'new'">
+
<else />
-
</if>
$forum[title]
</option>
<!-- Subforum pull-down menu --------------------------------------->


or maybe this

<!-- Subforum pull-down menu --------------------------------------->
<option value="$forum[forumid]">

<if condition="$forum[depth] == '2'">

</if>
<if condition="$forum[depth] == '3'">

</if>

<if condition="$forum[statusicon] == 'new'">
+
<else />
-
</if>

$forum[title]

</option>


or


<!-- Subforum pull-down menu --------------------------------------->
<option value="$forum[forumid]">
<if condition="$forum[depth] == '2'">
&nbsp; &nbsp;
</if>
<if condition="$forum[depth] == '3'">
&nbsp; &nbsp; &nbsp; &nbsp;
</if>
<if condition="$forum[statusicon] == 'new'">
+&nbsp;
<else />
-&nbsp;
</if>
$forum[title]
</option>
<!-- Subforum pull-down menu --------------------------------------->

leejohn02
11-06-2012, 05:42 PM
still doesnt work, this is getting annoying, any more suggestions will be appericated, the first part works, but for some reason it wont find the 2nd part and continues to use the 2nd level and not the 3rd

kh99
11-06-2012, 09:33 PM
Maybe this?

<vb:if condition="$forum[depth] == '2'">
&nbsp; &nbsp;
</vb:if>