vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 4 Articles (https://vborg.vbsupport.ru/forumdisplay.php?f=242)
-   -   vB4 Template Conditionals List (https://vborg.vbsupport.ru/showthread.php?t=231525)

princeedward 03-19-2010 12:02 PM

is there any conditional list to show something only if the said member is offline?
it means the below code belong to the user...so i want to hide it when they are online...
it can only be seen once that they are offline...is that possible guys?
Code:

<vb:if condition="$post['lastactivity']">
<dt>{vb:rawphrase last_online_activity}</dt><dd>{vb:raw post.lastactivity_date} {vb:raw post.lastactivity_time}</dd>
</vb:if>

appreciate any possible help on this guys...

thanks and best regards...

:o

princeedward 03-21-2010 10:40 AM

Quote:

Originally Posted by princeedward (Post 2006433)
is there any conditional list to show something only if the said member is offline?
it means the below code belong to the user...so i want to hide it when they are online...
it can only be seen once that they are offline...is that possible guys?
Code:

<vb:if condition="$post['lastactivity']">
<dt>{vb:rawphrase last_online_activity}</dt><dd>{vb:raw post.lastactivity_date} {vb:raw post.lastactivity_time}</dd>
</vb:if>

appreciate any possible help on this guys...

thanks and best regards...

:o

any cofirmation at least for the thread starter or some more experienced coder out there please...or any respectable staff?

hmmm...:rolleyes:

princeedward 03-24-2010 06:29 PM

Bump!-Bump!-Bump!

:mad:

TalkVirginia 03-24-2010 07:02 PM

It seems simple enough.. I wish I could help. Unfortunately I'm not familar in that area. Hopefully my response will help in attracting attention to your question. ;)

princeedward 03-26-2010 04:36 AM

TalkVirginia...thanks a lot but i guess and notice that most of well experienced coder are not quite there anymore or interested of replying to any message who needs help regarding code like this or product...we have still some around but not paying or giving attention to post message like this...but if you post it to paid forum...they are quite fast and your pm box is full in a minute or 2....:p well thats my own opinion only...well i am not like that or tryin not to be like that...as long as i can...i am willing always to share my knowledge...or anything that i know...without any single cents...thanks is quite enough...

anyway hope someone who is more experienced coder someday will go reply here and share his knowledge...i might share him too some cents...;)

best regards to all

:p

TalkVirginia 03-26-2010 08:33 AM

I think most want us to do as much research on our own, provide our analysis and findings before they offer any input. Granted, this is important to do but sometimes we need a knudge in the right direction... sometimes. :) Off the top of my head I would say you might be able to find something already existing in postbit and/or postbit_legacy where it shows the online status icon. I'll have to go back and re-read the thread I guess in case that's not what you are looking for.

--------------- Added [DATE]1269596340[/DATE] at [TIME]1269596340[/TIME] ---------------

Quote:

Originally Posted by M4tEUSh (Post 1993295)
So how to properly construct a condition with {vb:raw var}?

for example, if {vb:raw var} is smaller than 6, show XYZ

I don't know if anyone has answered this or if you have already figured it out but you would need to handle this logic in your php code then render the variable accordingly.

Mutt 04-18-2010 03:23 PM

I'd like to add that you can use AND & OR for example

Code:

<vb:if condition="$show['member'] AND THIS_SCRIPT == 'calendar'">show text</vb:if>

Olivier Turbis 04-25-2010 08:58 PM

What about show to users having one post? Please? Thank you in advance! :)

zipperty 05-02-2010 10:24 AM

Crystal clear - Subscribed.... thank you

Blackhat 05-02-2010 11:23 PM

I'm trying this in the css files stored among the templates. Anyone care to tell me whats wrong ? :)

Quote:

html {
<vb:if condition="$post['field26']">
background-image:url($post[field26]);
<vb:else />
background:{vb:stylevar doc_background};
</vb:if>
}


All times are GMT. The time now is 07:56 PM.

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.01486 seconds
  • Memory Usage 1,744KB
  • 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
  • (3)bbcode_code_printable
  • (3)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)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
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete