The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
||||
|
||||
vb_dropdowns not working (vb-html question)
for some reason i can't get the following drop downs to work, even though all other ones on the page do, can someone tell me where i'm going wrong please.
HTML Code:
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center" style="border-bottom-width:-1px"> <tr> <td class="tcat" width="100%">Pieces In Category<span class="normal">: $cats[title]</span></td> <td class="tcat" id="displyoptions" nowrap="nowrap"><a href="#goto_displyoptions">Display Options</a> <script type="text/javascript"> vbmenu_register("displyoptions"); </script></td> <if condition="$show['catsearch']"> <td class="tcat" id="catsearch" nowrap="nowrap"><a href="#goto_catsearch">Search Category</a> <script type="text/javascript"> vbmenu_register("catsearch"); </script></td> </if> </tr> </table> <table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center"> <tr> <td class="thead" width="100%"> <span style="float:$stylevar[right]">$vbphrase[rating]</a> $sortarrow[voteavg]</span> Piece Info </td> <td class="thead" width="150" align="center" nowrap="nowrap">Review Info</td> </tr> $browsebits </table> <br /> <if condition="$vboptions['usepopups']"> <br /> <!-- popup menu contents --> <!-- display options --> <div class="vbmenu_popup" id="displayoptions_menu" style="display:none"> <table cellpadding="4" cellspacing="1"> <tr> <td class="thead"> Display Options<a name="goto_displyoptions"></a> </td> </tr> <tr> <td class="vbmenu_option"> <div class="smallfont"> From The:<br /> <div id="clause"> <select name="daysprune"> <option value="1" $daysprunesel[1]>$vbphrase[last_day]</option> <option value="2" $daysprunesel[2]>$vbphrase[last_2_days]</option> <option value="7" $daysprunesel[7]>$vbphrase[last_week]</option> <option value="10" $daysprunesel[10]>$vbphrase[last_10_days]</option> <option value="14" $daysprunesel[14]>$vbphrase[last_2_weeks]</option> <option value="30" $daysprunesel[30]>$vbphrase[last_month]</option> <option value="45" $daysprunesel[45]>$vbphrase[last_45_days]</option> <option value="60" $daysprunesel[60]>$vbphrase[last_2_months]</option> <option value="75" $daysprunesel[75]>$vbphrase[last_75_days]</option> <option value="100" $daysprunesel[100]>$vbphrase[last_100_days]</option> <option value="365" $daysprunesel[365]>$vbphrase[last_year]</option> <option value="-1" $daysprunesel[all]>$vbphrase[beginning]</option> </select> </div> Order By: <br /> <div id="order"> <select name="sort"> <option value="title" $sort[title]>Title</option> <option value="postdate" $sort[lastpost]>Date Posted</option> <option value="lastreview" $sort[lastpost]>Last Review Date</option> <option value="reviewcount" $sort[replycount]>Number Of Reviews</option> <option value="views" $sort[views]>Views</option> <option value="postusername" $sort[postusername]>Author</option> <option value="voteavg" $sort[voteavg]>Rating</option> </select> </div> Sort By: <br /> <div id="direction"> <select name="order"> <option value="asc" $order[asc]>$vbphrase[ascending]</option> <option value="desc" $order[desc]>$vbphrase[descending]</option> </select> </div> <div id="submit"> <input type="submit" class="button" value="Show Pieces" /> </div> </div> </td> </tr> <table> </div> <!-- / display options --> <!-- / popup menu contents --> <else /> <!-- controls for non-popup browsers --> <b>this ++++ aint working</b> <!-- / controls for non-popup browsers --> </if> <if condition="$vboptions['popups'] AND $show['catsearch']"> <!-- search this cat --> <div class="vbmenu_popup" id="catsearch_menu" style="display:none"> <form action="find.php" method="post"> <table cellpadding="4" cellspacing="1" border="0"> <tr> <td class="thead">Search Category<a name="goto_catsearch"></a></td> </tr> <tr> <td class="vbmenu_option" title="nohilite" align="center"> <input type="hidden" name="s" value="$session[sessionhash]" /> <input type="hidden" name="do" value="process" /> <input type="hidden" name="catchoice" value="$cat[catid]" /> <input type="hidden" name="formuserid" value="$bbuserinfo[userid]" /> Title:<br/><input type="text" class="bginput" name="query" size="20" style="width:175px" /><br/> Author:<br/><input type="text" class="bginput" name="query" size="20" style="width:175px" /><br/> Text:<br/><input type="text" class="bginput" name="query" size="20" style="width:175px" /><br/> $gobutton<br /> </td> </tr> </table> </form> </div> <!-- / search this cat --> </if> |
#2
|
||||
|
||||
Have a look here: http://www.vbulletin.com/docs/html/m...tes_vbmenu#top
I couldn't find anything on the first glance, two things I did see: You can use $show['popups'] instead of $vboptions['usepopups'], as the first will check if the browser actually supports popups. And you could use the CSS class vbmenu_control for the control... |
#3
|
||||
|
||||
here's an edited version:
HTML Code:
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center" style="border-bottom-width:-1px"> <tr> <td class="tcat" width="100%">Pieces In Category<span class="normal">: $cats[title]</span></td> <td class="vbmenu_control" id="displyoptions" nowrap="nowrap"><a href="#goto_displyoptions" onclick="return toggle_collapse('displyoptions')">Display Options</a> <script type="text/javascript"> vbmenu_register("displyoptions"); </script></td> </tr> </table> <if condition="$show['popups']"> <div class="vbmenu_popup" id="displyoptions_menu" style="display:none"> <table cellpadding="4" cellspacing="1"> <tr> <td class="thead"> Display Options<a name="goto_displyoptions"></a> </td> </tr> <tr> <td class="vbmenu_option"><div class="smallfont"> From The:<br /> <div id="clause"> <select name="daysprune"> <option value="1" $daysprunesel[1]>$vbphrase[last_day]</option> <option value="2" $daysprunesel[2]>$vbphrase[last_2_days]</option> <option value="7" $daysprunesel[7]>$vbphrase[last_week]</option> <option value="10" $daysprunesel[10]>$vbphrase[last_10_days]</option> <option value="14" $daysprunesel[14]>$vbphrase[last_2_weeks]</option> <option value="30" $daysprunesel[30]>$vbphrase[last_month]</option> <option value="45" $daysprunesel[45]>$vbphrase[last_45_days]</option> <option value="60" $daysprunesel[60]>$vbphrase[last_2_months]</option> <option value="75" $daysprunesel[75]>$vbphrase[last_75_days]</option> <option value="100" $daysprunesel[100]>$vbphrase[last_100_days]</option> <option value="365" $daysprunesel[365]>$vbphrase[last_year]</option> <option value="-1" $daysprunesel[all]>$vbphrase[beginning]</option> </select> </div> Order By: <br /> <div id="order"> <select name="sort"> <option value="title" $sort[title]>Title</option> <option value="postdate" $sort[lastpost]>Date Posted</option> <option value="lastreview" $sort[lastpost]>Last Review Date</option> <option value="reviewcount" $sort[replycount]>Number Of Reviews</option> <option value="views" $sort[views]>Views</option> <option value="postusername" $sort[postusername]>Author</option> <option value="voteavg" $sort[voteavg]>Rating</option> </select> </div> Sort By: <br /> <div id="direction"> <select name="order"> <option value="asc" $order[asc]>$vbphrase[ascending]</option> <option value="desc" $order[desc]>$vbphrase[descending]</option> </select> </div> <div id="submit"> <input type="submit" class="button" value="Show Pieces" /> </div> </div></td> </tr> </table> </div> </if> |
#4
|
||||
|
||||
not a bad idea but i need it as a dropdown rather than a collapseable object.
|
#5
|
||||
|
||||
huh?
|
#6
|
||||
|
||||
i need a drop down menu not for something to open and close.
|
#7
|
||||
|
||||
have you installed/tested it as-is?
it's similar to the navbar/forum tools/search this forum menu options If that's not what you want then I am at a lost. If you are speaking about the actual dropdown options (objects) and not the effect ... you need to wrap it with a <form> tag -- something which you are lacking in the above example. |
#8
|
||||
|
||||
nah i never tried, which was very rude of me so i apologise i should've said that first, however upon reading it, it appeared to act more like the forumbits than the navbar.
anyway i got the left one working (displayoptions) however it's showing both dropdowns as one men HTML Code:
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center" style="border-bottom-width:-1px"> <tr> <td class="tcat" width="100%">Pieces In Category<span class="normal">: $cats[title]</span></td> <td id="displyoptions" class="vbmenu_control" nowrap="nowrap"><a href="#goto_displyoptions">Display Options</a> <script type="text/javascript"> vbmenu_register("displyoptions"); </script></td> <if condition="$show['catsearch']"> <td id="categorysearch" class="vbmenu_control" nowrap="nowrap"><a href="#goto_categorysearch">Search Category</a> <script type="text/javascript"> vbmenu_register("categorysearch"); </script></td> </if> </tr> </table> <if condition="$show['popups']"> <!-- popup menu contents --> <!-- display options --> <div class="vbmenu_popup" id="displyoptions_menu" style="display:none"> <form action="browse.php" method="post"> <table cellpadding="4" cellspacing="1"> <tr> <td class="thead" colspan="2"> Display Options </td> </tr> <tr> <td class="vbmenu_option"> <span class="smallfont"> From The: </span> </td> <td class="vbmenu_option"> <span class="smallfont"> <select name="daysprune"> <option value="1" $daysprunesel[1]>$vbphrase[last_day]</option> <option value="2" $daysprunesel[2]>$vbphrase[last_2_days]</option> <option value="7" $daysprunesel[7]>$vbphrase[last_week]</option> <option value="10" $daysprunesel[10]>$vbphrase[last_10_days]</option> <option value="14" $daysprunesel[14]>$vbphrase[last_2_weeks]</option> <option value="30" $daysprunesel[30]>$vbphrase[last_month]</option> <option value="45" $daysprunesel[45]>$vbphrase[last_45_days]</option> <option value="60" $daysprunesel[60]>$vbphrase[last_2_months]</option> <option value="75" $daysprunesel[75]>$vbphrase[last_75_days]</option> <option value="100" $daysprunesel[100]>$vbphrase[last_100_days]</option> <option value="365" $daysprunesel[365]>$vbphrase[last_year]</option> <option value="-1" $daysprunesel[all]>$vbphrase[beginning]</option> </select> </span> </td> </tr> <tr> <td class="vbmenu_option"> <span class="smallfont"> Order By: </span> </td> <td class="vbmenu_option"> <span class="smallfont"> <select name="sort"> <option value="title" $sort[title]>Title</option> <option value="postdate" $sort[lastpost]>Date Posted</option> <option value="lastreview" $sort[lastpost]>Last Review Date</option> <option value="reviewcount" $sort[replycount]>Number Of Reviews</option> <option value="views" $sort[views]>Views</option> <option value="postusername" $sort[postusername]>Author</option> <option value="voteavg" $sort[voteavg]>Rating</option> </select> </span> </td> </tr> <tr> <td class="vbmenu_option"> <span class="smallfont"> Sort By: </span> </td> <td class="vbmenu_option"> <span class="smallfont"> <select name="order"> <option value="asc" $order[asc]>$vbphrase[ascending]</option> <option value="desc" $order[desc]>$vbphrase[descending]</option> </select> </span> </td> </tr> <tr> <td class="vbmenu_option" colspan="2" align="center"> <span class="smallfont"> <input type="submit" class="button" value="Show Pieces" /> </span> </td> </tr> <table> </form> </div> <!-- / display options --> </if> <if condition="$show['popups'] AND $show['catsearch']"> <!-- search this cat --> <div class="vbmenu_popup" id="categorysearch_menu" style="display:none"> <form action="find.php" method="post"> <table cellpadding="4" cellspacing="1" border="0"> <tr> <td class="thead" colspan="2">Search Category</td> </tr> <tr> <td class="vbmenu_option" title="nohilite"> Title: </td> <td> <input type="text" class="bginput" name="query" size="20" style="width:175px" /> </td> </tr> <tr> <td class="vbmenu_option" title="nohilite"> Author: </td> <td> <input type="text" class="bginput" name="query" size="20" style="width:175px" /> </td> </tr> <tr> <td class="vbmenu_option" title="nohilite"> Text: </td> <td> <input type="text" class="bginput" name="query" size="20" style="width:175px" /> </td> </tr> <tr> <td class="vbmenu_option" title="nohilite" align="center" colspan="2"> <input type="hidden" name="s" value="$session[sessionhash]" /> <input type="hidden" name="do" value="process" /> <input type="hidden" name="catchoice" value="$cat[catid]" /> <input type="hidden" name="formuserid" value="$bbuserinfo[userid]" /> $gobutton </td> </tr> </table> </form> </div> <!-- / search this cat --> <!-- / popup menu contents --> <else /> <!-- controls for non-popup browsers --> <b>this ++++ aint working</b> <!-- / controls for non-popup browsers --> </if> |
#9
|
||||
|
||||
try closing the <table> tag...
|
#10
|
||||
|
||||
you're right i had a <table> tag instead of a </table>
thanks princeton, all working perfectly now |
Thread Tools | |
Display Modes | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|