vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 Programming Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=15)
-   -   Online status conditional? (https://vborg.vbsupport.ru/showthread.php?t=137806)

Sychev_S 01-28-2007 11:37 PM

Online status conditional?
 
Let's say in memberinfo I want to show certain picture if user is online and certain picture if user is offline. Is it possible to do that with "if" conditionals?

Mr Chad 01-29-2007 01:31 AM

yes your looking for a usergroup conditional. or if not guest

Sychev_S 01-29-2007 02:38 AM

hm, not to registered users, but to Online Registered users.

darnoldy 01-29-2007 04:24 AM

Quote:

Originally Posted by Sychev_S (Post 1169471)
hm, not to registered users, but to Online Registered users.

Okay, I'm confused-- if a person is not online, how would they see the content?

Sychev_S 01-29-2007 05:57 AM

Sorry I think I confused myself there. First post edited.

Let's say in memberinfo I want to show certain picture if user is online and certain picture if user is offline. Is it possible to do that with "if" conditionals?

something like <if $userinfo[onlinestatus]==1> or something like that.

darnoldy 01-29-2007 04:06 PM

Quote:

Originally Posted by Sychev_S (Post 1169557)
Let's say in memberinfo I want to show certain picture if user is online and certain picture if user is offline. Is it possible to do that with "if" conditionals?

$userinfo[onlinestatus] should work for what you want.

Sychev_S 01-29-2007 04:59 PM

but how do I set it to online/offline?
I tried $userinfo[onlinestatus]==1 , it doesnt seem to work. Is there any other way?

da420 01-29-2007 06:16 PM

Offline.
Code:

<if condition="$onlinestatus==0">
Online.
Code:

<if condition="$onlinestatus==1">
Invisible.
Code:

<if condition="$onlinestatus==2">

Sychev_S 01-30-2007 12:43 AM

hm thanks but this doesnt seem to work in memberinfo...only postbit

da420 02-03-2007 08:01 PM

Should go in the 'postbit_onlinestatus' template. It's best to edit that template and just leave the memberinfo and postbit templates alone.


All times are GMT. The time now is 02:47 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.01369 seconds
  • Memory Usage 1,728KB
  • 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
  • (2)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (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