Go Back   vb.org Archive > vBulletin 3 Discussion > vB3 General Discussions

Reply
 
Thread Tools Display Modes
  #1  
Old 10-31-2005, 11:11 PM
Gellpak Gellpak is offline
 
Join Date: Jul 2002
Location: Raleigh, NC
Posts: 20
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Conditional list?

Is there a list of conditionals that can be used in the templates?

I'm attempting to make the whole row of each thread with a new post have a different color than those which have no new posts. It's probably possible to do this with the $thread[statusicon] variable, but there are (looks like) 18 possible values of that, so it would get to be a headache. There has to be a variable already set that indicates whether the current thread has new posts...?
Reply With Quote
  #2  
Old 11-01-2005, 12:09 AM
akanevsky akanevsky is offline
 
Join Date: Apr 2005
Posts: 3,972
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

No, there is no list of conditionals, just as there is no list of all the coding possibilities of any given language.
The list is only limited by your imagination and coding skills
Reply With Quote
  #3  
Old 11-01-2005, 12:27 AM
Gellpak Gellpak is offline
 
Join Date: Jul 2002
Location: Raleigh, NC
Posts: 20
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Dark Visor
No, there is no list of conditionals, just as there is no list of all the coding possibilities of any given language.
The list is only limited by your imagination and coding skills
Fair enough, is there a preset variable that does what the above post describes? There must be, in order for vb to make the decisions it needs to on a post-to-post basis. These types of default existing variables were what I was referring to.
Reply With Quote
  #4  
Old 11-01-2005, 01:11 AM
akanevsky akanevsky is offline
 
Join Date: Apr 2005
Posts: 3,972
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I'd suggest using <if condition="$show['gotonewpost']"> for your particular case.
Reply With Quote
  #5  
Old 11-01-2005, 01:26 AM
Gellpak Gellpak is offline
 
Join Date: Jul 2002
Location: Raleigh, NC
Posts: 20
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Dark Visor
I'd suggest using <if condition="$show['gotonewpost']"> for your particular case.
Hmm... didn't have any effect.
Reply With Quote
  #6  
Old 11-01-2005, 05:46 PM
akanevsky akanevsky is offline
 
Join Date: Apr 2005
Posts: 3,972
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

This is just a tip. You need to figure out the rest of the HTML yourself...
Maybe:

...somehtmlcode...
<if condition="$show['gotonewpost']">
style="background-color:white;"
</if>
...morehtmlcode...
Reply With Quote
  #7  
Old 11-01-2005, 06:13 PM
Gellpak Gellpak is offline
 
Join Date: Jul 2002
Location: Raleigh, NC
Posts: 20
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Well that goes without saying... I put some sample code between those tags, just to see where it worked, and couldn't get it to ever show up, under various conditions.

Code:
<if condition="$show['gotonewpost']">NEW</if>
Reply With Quote
  #8  
Old 11-01-2005, 06:16 PM
akanevsky akanevsky is offline
 
Join Date: Apr 2005
Posts: 3,972
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Weird, it works on my board. What template are you trying to use that code in?
Reply With Quote
  #9  
Old 11-01-2005, 06:26 PM
T3MEDIA T3MEDIA is offline
 
Join Date: Dec 2004
Posts: 944
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Gellpak
Is there a list of conditionals that can be used in the templates?

I'm attempting to make the whole row of each thread with a new post have a different color than those which have no new posts. It's probably possible to do this with the $thread[statusicon] variable, but there are (looks like) 18 possible values of that, so it would get to be a headache. There has to be a variable already set that indicates whether the current thread has new posts...?
I guess people dont get what you mean. I do. I asked about this ages ago but I am on ignore at the moment.

I was also curious if there was a way to pull information from a variable in templates.

Example. I want to have information on user 200

insted of $user[fieldx] I want $pull(200)[fieldx] so this phantom 'pull' command works as the user or userinfo string but can be used at anytime anywhere.

would solve a kazillion hacks that need extra information. say gender on a pager or ummm avatar of who sent you admeration the list could go on and on.


Im on 3.0.x but it would be nice to see someone have this for their system.
Reply With Quote
  #10  
Old 11-01-2005, 06:27 PM
Gellpak Gellpak is offline
 
Join Date: Jul 2002
Location: Raleigh, NC
Posts: 20
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

threadbit... and what's weird is that there are several other places in the template where it shows up also, but doesn't seem to be doing anything either.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 04:54 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.04463 seconds
  • Memory Usage 2,251KB
  • Queries Executed 13 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (1)bbcode_code
  • (3)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (10)postbit
  • (10)postbit_onlinestatus
  • (10)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete