vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   moved Forumjump - little problem (https://vborg.vbsupport.ru/showthread.php?t=201796)

kurti 01-14-2009 09:42 PM

moved Forumjump - little problem
 
hi,
in the SHOWTHREAD template i moved the Forumjump menu
right next to the Moderation menu:
http://img407.imageshack.us/img407/7977/jumpbp6.jpg

the problem is that Forumjump does not work properly now.
i think its because the GO buttons at the forum jump and the Moderation
probably have the same ID / name or so.
When i want to use the Forumjump it reacts like
i clicked on the GO of the Moderation menu without any thread being marked before.
and it says "You did not select any posts to which the action you picked can be applied."

could you please tell me what i should change so the Forumjump works?
(im not 100% sure which and how many changes are necessary for this)



controls part from the SHOWTHREAD template:
Code:

<!-- controls below postbits -->

<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center" style="border-bottom-width:0px">
<tr>

<!--REPLY BUTTON-->
<if condition="$show['largereplybutton']">
<td class="tcat" style="padding-left:25px;">
<a href="newreply.php?$session[sessionurl]do=newreply&amp;noquote=1&amp;p=$FIRSTPOSTID" rel="nofollow">
<if condition="$show['closethread']">
<img src="$stylevar[imgdir_button]/reply.gif" alt="$vbphrase[reply]" border="0" /><else />
<img src="$stylevar[imgdir_button]/threadclosed.gif" alt="$vbphrase[closed_thread]" border="0" /></if>
</a>
</td>
<else />
<td class="tcat" style="padding-left:25px">&nbsp;</td>
</if>

<!--PAGENAV-->
<if condition="$show['pagenav']">
<td class="tcat" align="$stylevar[right]" nowrap="nowrap" style="padding-right:25px;">
$pagenav
</td>
</if>
</tr>
</table>





<table cellpadding="0" cellspacing="0" border="0" width="100%">
<tr valign="top">


<!--FORUMJUMP-->
<td align="$stylevar[right]" style="width:100%;padding-left:25px;padding-right:25px;">
<div class="smallfont" style="text-align:$stylevar[left]; white-space:nowrap; float:$stylevar[right]">
$forumjump
</div>
</td>


<!--MODERATION-->

<if condition="$show['inlinemod']">
<td align="$stylevar[right]" style="padding-right:25px;">
<if condition="$show['inlinemod']">
<div class="smallfont" style="text-align:$stylevar[left]; white-space:nowrap; float:$stylevar[right]">
<strong>$vbphrase[moderation]</strong>
<br />
<select name="do">
<if condition="$show['managethread'] OR $show['spamctrls'] OR $show['managepost'] OR $show['approvepost'] OR $show['approveattachment'] OR $template_hook['inlinemod_post_bottom']">
<optgroup label="$vbphrase[option]">
<if condition="$show['managethread']">
<option value="mergeposts">$vbphrase[merge_posts]</option>
<option value="moveposts">$vbphrase[move_posts]</option>
<option value="copyposts">$vbphrase[copy_posts]</option>
</if>
<if condition="$show['spamctrls']">
<option value="spampost">$vbphrase[delete_posts_as_spam]</option>
</if>
<if condition="$show['managepost']">
<option value="deleteposts">$vbphrase[delete_posts]</option>
<option value="undeleteposts">$vbphrase[undelete_posts]</option>
</if>
<if condition="$show['approvepost']">
<option value="approveposts">$vbphrase[approve_posts]</option>
<option value="unapproveposts">$vbphrase[unapprove_posts]</option>
</if>
<if condition="$show['approveattachment']">
<option value="approveattachments">$vbphrase[approve_attachments]</option>
<option value="unapproveattachments">$vbphrase[unapprove_attachments]</option>
</if>
$template_hook[inlinemod_post_bottom]
</optgroup>
</if>
<optgroup label="____________________">
<option value="viewpost">$vbphrase[view_selected_posts]</option>
<option value="clearpost">$vbphrase[clear_post_list]</option>
</optgroup>
</select>
<input type="submit" class="button" id="inlinego" value="$vbphrase[go]" />
<input type="hidden" name="s" value="$session[sessionhash]" />
<input type="hidden" name="securitytoken" value="$bbuserinfo[securitytoken]" />
<input type="hidden" name="threadid" value="$threadinfo[threadid]" />
<input type="hidden" name="p" value="$postid" />
<input type="hidden" name="url" value="$url" />
</div>




<script type="text/javascript" src="clientscript/vbulletin_inlinemod.js?v=$vboptions[simpleversion]"></script>
<script type="text/javascript">
<!--
inlineMod = new vB_Inline_Mod('inlineMod', 'post', 'inlinemodform', '$vbphrase[go_x]');
//-->
</script>

</if>
</td>
</if>
</tr>
</table>
<!-- / controls below postbits -->



forumjump template:

Code:

<div class="smallfont" style="text-align:$stylevar[left];white-space:nowrap;">

<form action="forumdisplay.php" method="get">
<input type="hidden" name="s" value="$session[sessionhash]" />
<input type="hidden" name="daysprune" value="$daysprune" />


        <strong>$vbphrase[forum_jump]</strong><br />
        <select name="f" onchange="this.form.submit();">

                <optgroup label="$vbphrase[site_areas]">
                        <option value="cp" $frmjmpsel[usercp]>$vbphrase[user_control_panel]</option>
                        <option value="pm" $frmjmpsel[pm]>$vbphrase[private_messages]</option>
                        <option value="wol" $frmjmpsel[wol]>$vbphrase[whos_online]</option>
                        <option value="home" $frmjmpsel[home]>$vbphrase[forums_home]</option>
                </optgroup>

                <if condition="$jumpforumbits">
                <optgroup label="$vbphrase[forums]">
                $jumpforumbits
                </optgroup>
                </if>
        </select>$gobutton
        </form>
</div>


gobutton template:
Code:

<input type="submit" class="button" value="$vbphrase[go]"  />

SEOvB 01-14-2009 10:33 PM

make sure you dont have a form within a form

kurti 01-14-2009 10:45 PM

ah, thats it. theres a form around that part in the SHOWTHREAD template.

what could be an easy trick to make it work anyway?

should i simply copy the code from the forumjump template code
into SHOWTHREAD ...but leaving out the extra form around it?

or could i close the SHOWTHREAD form right before the forumjump variable
and open it again after it?:o

Lynne 01-14-2009 10:56 PM

You can't close it and then open it. Why not add the forumjump menu onto the right side of the moderation menu after the end of the form?

kurti 01-15-2009 01:40 AM

ok ill try. :)
the end of the "controls below postbits" table (in the SHOWTHREAD template)
looks like this. the form is closing a bit after that...

Code:

</td>
</if>
</tr>
</table>
<!-- / controls below postbits -->

<if condition="$show['inlinemod']">
$spacer_close
</form>




would it be ok for the form to change it like this:
(the $spacer_open is within the form)

Code:

</td>
</if>

</form>

<!--FORUMJUMP-->
<td align="$stylevar[right]" style="width:100%;padding-left:25px;padding-right:25px;">
<div class="smallfont" style="text-align:$stylevar[left]; white-space:nowrap; float:$stylevar[right]">
$forumjump
</div>
</td>
<!--end FORUMJUMP-->


</tr>
</table>
<!-- / controls below postbits -->


<if condition="$show['inlinemod']">
$spacer_close

or should i create a new table for the forumjump next to that table? :erm:

Lynne 01-15-2009 02:24 AM

The only problem I see there is you are adding in another column to the table and so you really need to take a look at that table and make sure all the columns add up properly.

kurti 01-15-2009 02:52 PM

yes, theres just one row in this table so its ok.

it all works fine now. thanks very much for the help! :)


All times are GMT. The time now is 10:22 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01488 seconds
  • Memory Usage 1,747KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (5)bbcode_code_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (7)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete