vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   Thread ID into collapseobj (https://vborg.vbsupport.ru/showthread.php?t=112149)

TygerTyger 04-04-2006 04:16 PM

Thread ID into collapseobj
 
PHP syntax isn't my strongest point...I want to put a $thread[threadid] value inside a $vbcollapse[collapseobj_threadidgoeshere] and it's giving me:

Parse error: parse error, unexpected T_VARIABLE, expecting ']'

The $thread[threadid] is used inside tlist inside the same template, what is the problem with putting it where I want?

Thanks for your help.

Edit: Specifically this is what I want:

id="collapseobj_foo$thread[threadid]" style="$vbcollapse[collapseobj_foo$thread[threadid]]"

The id is fine, the style one gives the error. As yet curly braces and/or escaping have made no difference.

TygerTyger 04-06-2006 10:17 AM

No? Nobody knows why the threadid var would produce an error inside the style tag?

SleekSkins 04-06-2006 04:08 PM

I don't think you can use [] inside [], but I don't know a way around it either.

TygerTyger 04-06-2006 04:40 PM

You can, it's done in several other places in the postbit template.

DeveloperGuy 05-29-2006 08:56 PM

Did anyone figure out how to do this?

TygerTyger 05-29-2006 09:01 PM

Well I never did, and the guys on the vBulletin.com forum seemed equally stumped as to how it could be done. In fact they didn't even appear to know why it was used elsewhere in the same template but produced an error where I wanted it.

I'd still like to do be able to do it.

ams3521 05-15-2008 01:39 AM

Hello does anyone know how to make a menu default as closed when using this code? I have a sidebar on my forum and the menus default as open. I would like them to stay closed. Thanks

Quote:

<!-- partners -->
<div class="leftmenutitle">
<div class="floatleft">Stuff</div><div class="floatright"><a href="#top" onClick="return toggle_collapse('partners8')"><img id="collapseimg_partners" src="$vboptions[bburl]/skin_images/buttons/collapse_tcat$vbcollapse[collapseimg_tcat].gif" alt="" border="0" /></a></div>
</div>
<div id="collapseobj_partners8" style="$vbcollapse[collapseobj_partners8]">
<div class="leftmenucontent">
<ul class="partnerslist">
<li><a href="http://www.thedailypunt.com/forum/index.php?styleid=47" target="_blank">Old Theme</a></li>
<li><a href="http://www.thedailypunt.com/forum/index.php?styleid=57" target="_blank">Mobile Theme</a></li>
<li><a href="http://www.thedailypunt.com/forum/modapp.php" target="_self">Forum Mods Req</a></li>
<li><a href="http://thedailypunt.com/tdps-forum/" target="_self">tDPS Forum</a></li>
<li><a href="http://thedailypunt.com/wp-signup.php" target="_blank">Create tDPS</a></li>
</ul>
</div>
</div>
<!-- / partners -->

Dismounted 05-15-2008 06:43 AM

Trigger the toggle_collapse() function with an "onload" parameter.


All times are GMT. The time now is 09:18 AM.

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.02333 seconds
  • Memory Usage 1,726KB
  • 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
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (8)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