vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin.org Site Feedback (https://vborg.vbsupport.ru/forumdisplay.php?f=7)
-   -   What is "clear session"? (https://vborg.vbsupport.ru/showthread.php?t=31888)

Admin 10-31-2001 01:39 PM

[QUOTE]Originally posted by MrLister
:) ditto... i dosed off after the 3rd line..

eva2000 10-31-2001 01:40 PM

Quote:

Originally posted by FireFly

LMAO :china:

Sorry :o

needs formatting... structure and lots of bullet point notes to keep us glued to the message ;)

SWFans.net 11-02-2001 07:43 PM

I like the Clear Session feature and wonder if Firefly would share with us how its done?

Admin 11-02-2001 07:51 PM

Add this action to member.php:
Code:

// ############################### start clear sessions ###############################
if ($action=="clears") {
  include("./global.php");
  if ($bbuserinfo[userid]!=0 and $bbuserinfo[userid]!=-1) {
    $DB_site->query("UPDATE user SET lastactivity='".(time()-$cookietimeout)."',lastvisit='".time()."' WHERE userid='$bbuserinfo[userid]'");
  }
  $DB_site->query("DELETE FROM session WHERE sessionhash='".addslashes($session[dbsessionhash])."'");
  $DB_site->query("DELETE FROM session WHERE userid='$bbuserinfo[userid]'");
  eval("standarderror(\"".gettemplate("error_sessionclear")."\");");
}

and link to member.php?s=$session[sessionhash]&action=clears
Add a template named error_sessionclear and put your message there.

SWFans.net 11-02-2001 08:03 PM

Thank ya. :pleased:

JJR512 11-02-2001 11:53 PM

And all this does--the only thing at all--is remove you from the Who's Online? It doesn't mark anything as read, it doesn't log you out, it doesn't do anything else, other than take you off Who's Online?

I'm still not sure if I see what the point is. If someone can explain it to me a little better so that I can explain it to my members so we'll all know what to do with it, I'd really appreciate it.

Palmer ofShinra 11-03-2001 03:40 AM

It does not log you out, which would clear your cookie and prevent an auto-login next time.

It does remove you from Who's Online.

Why? Because if you leave the site, you show up on Who's Online for 15 minutes after your last activity.

It's just if you don't want to show up on Who's Online without actually logging out.

Admin 11-03-2001 06:45 AM

And it does mark all forums read.
If you don't want that, remove this code from the code above:
Code:

  if ($bbuserinfo[userid]!=0 and $bbuserinfo[userid]!=-1) {
    $DB_site->query("UPDATE user SET lastactivity='".(time()-$cookietimeout)."',lastvisit='".time()."' WHERE userid='$bbuserinfo[userid]'");
  }


SirSteve 01-13-2002 02:45 PM

Well, this works but it still shows the user as ONLINE in their Profile and in the CURRENTLY ACTIVE user list.


All times are GMT. The time now is 12:33 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.01687 seconds
  • Memory Usage 1,727KB
  • 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
  • (2)bbcode_code_printable
  • (1)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
  • (9)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