Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 2.x > vBulletin 2.x Full Releases
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Details »»

Version: , by bira bira is offline
Developer Last Online: Jun 2013 Show Printable Version Email this Page

Version: 2.2.x Rating:
Released: 12-09-2001 Last Update: Never Installs: 109
 
No support by the author.

Hi,

This is something that is common in IRC - /me is away

In BBs, a user is either online or offline (or invisible).

But, on my Bulletin Board, the folks created such a community that every time someone goes on a holiday or goes offline for a while, he/she posts a new thread to annouce they're 'away.

So, I wrote a hack allowing a user to change his/her status to "away", including a return date and an away reason which will show up in their profile.

Likewise, the online/offline icon in postbit and buddy list will change to an away icon (a very faded version of the 'offline' one).

Some demo captures:

The Edit Profile screen, when a user is NOT away:



The Edit Profile screen when a user IS away:



The Get Info (User Profile) screen when a user IS away:



The Get Info (User Profile) screen when a user is NOT away:



The postbit icon when a user is away:




How to install:

Download the attached zip file. Upload away.gif to your images dir (or create your own away.gif).

Upload install_awayuser.php to your admin dir and follow the instructions.

Cheers,

Bira

newest version by sho here:
https://vborg.vbsupport.ru/showthrea...606#post287606

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #142  
Old 12-19-2001, 09:04 AM
Tarion's Avatar
Tarion Tarion is offline
 
Join Date: Nov 2001
Location: Germany
Posts: 57
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

great bira, it works perfect now youre wonderfull and it's a very good hack.

THX for your fast support
Reply With Quote
  #143  
Old 12-19-2001, 09:05 AM
bira's Avatar
bira bira is offline
 
Join Date: Nov 2001
Posts: 387
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

oops, sorry Remi -- yes, that's the correct order

Thanks
Reply With Quote
  #144  
Old 12-22-2001, 03:30 PM
the_sisko's Avatar
the_sisko the_sisko is offline
 
Join Date: Oct 2001
Location: Hamburg,Germany
Posts: 132
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Just a small add on I created and want to share with you:
It's just a small CP add on which shows all away users.

To add it do the following:
In admin/index.php
FIND:
PHP Code:
makenavselect("Users"); 
Add above:
PHP Code:
makenavoption("Find away user","user.php?action=findaway"); 
In admin/user.php
FIND:
PHP Code:
cpfooter(); 
Add above:
PHP Code:
// ###################### Start findaway #######################
if ($action=="findaway") {

  if (
$orderby=="") {
    
$orderby="awaydate";
  }
  if (
$limitstart=="") {
    
$limitstart=0;
  } else {
    
$limitstart--;
  }
  if (
$limitnumber=="") {
    
$limitnumber=99999999;
  }

  
$users=$DB_site->query("SELECT user.userid,username,FROM_UNIXTIME(awaydate) AS awaydate,returndate,awayreason,away FROM user WHERE away = 1 ORDER BY $orderby $direction LIMIT $limitstart,$limitnumber");
  
$countusers=$DB_site->query_first("SELECT COUNT(*) AS users FROM user WHERE away=1");
  
$limitfinish=$limitstart+$limitnumber;

    echo 
"<p>Showing records ".($limitstart+1)." to ".iif($limitfinish>$countusers[users],$countusers[users],$limitfinish)." of $countusers[users]. Click username to view forum profile.</p>";
  
doformheader("","");

  echo 
"<tr class='tblhead'>";
    echo 
"<td><p><b><span class='tblhead'>Name</span></b></p></td>";
    echo 
"<td><p><b><span class='tblhead'>Options</span></b></p></td>";
    echo 
"<td><p><b><span class='tblhead'>Away reason</span></b></p></td>";
    echo 
"<td><p><b><span class='tblhead'>Away date</span></b></p></td>";
    echo 
"<td><p><b><span class='tblhead'>Return date</span></b></p></td>";
  echo 
"</tr>\n";

  while (
$user=$DB_site->fetch_array($users)) {

    echo 
"<tr class='".getrowbg()."'>";
      echo 
"<td><p><a href='../member.php?s=$session[sessionhash]&action=getinfo&userid=$user[userid]' target='_blank'>$user[username]</a>&nbsp;</p></td>";
      echo 
"<td><p>".
                
makelinkcode("edit","user.php?s=$session[sessionhash]&action=edit&userid=$user[userid]")."
                </p></td>"
;
      echo 
"<td><p>$user[awayreason]&nbsp;</p></td>";
      echo 
"<td><p>$user[awaydate]&nbsp;</p></td>";
      echo 
"<td><p>$user[returndate]</p></td>";
    echo 
"</tr>\n";
  } 
// end while
    
  
echo "</table></td></tr></table></form>";

  if (
$limitnumber!=99999999 AND $limitfinish<$countusers[users]) {
    
doformheader("user","findaway");
    
makehiddencode("ausername",$ausername);
    
makehiddencode("awaydate",$awaydate);
    
makehiddencode("returndate",$returndate);
    
makehiddencode("awayreason",$awayreason);
    
makehiddencode("orderby",$orderby);
    
makehiddencode("direction",$direction);
    
makehiddencode("limitstart",$limitstart+$limitnumber+1);
    
makehiddencode("limitnumber",$limitnumber);
   echo 
"<input type=submit value=\"Show Next Page\">";
  }



Upload the two files and you will find a new link under Users: "Find away user ".

Thats all
Not the best, but it works
Reply With Quote
  #145  
Old 12-22-2001, 03:33 PM
bira's Avatar
bira bira is offline
 
Join Date: Nov 2001
Posts: 387
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

hey the_sisko - long time no see!!!

You know, I was wondering where you were -- I never got the chance to thank you for the Links Directory hack :up: :up: :up:

Thanks for the add-on
Reply With Quote
  #146  
Old 12-22-2001, 03:41 PM
bira's Avatar
bira bira is offline
 
Join Date: Nov 2001
Posts: 387
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
user.php[high]4[/high]?action=findaway
Not sure the 4 is required
Reply With Quote
  #147  
Old 12-22-2001, 03:53 PM
the_sisko's Avatar
the_sisko the_sisko is offline
 
Join Date: Oct 2001
Location: Hamburg,Germany
Posts: 132
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thx bira,...

Changed post above with .php. Its my system running on .php4...I always forget to change it
Reply With Quote
  #148  
Old 12-22-2001, 05:44 PM
Sadie Frost's Avatar
Sadie Frost Sadie Frost is offline
 
Join Date: Dec 2001
Location: Pittsburgh
Posts: 307
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Great add-on! That will be so useful!

Could someone help me with what to put in the postbit template to display in their posts when people are away?

And did somebody say links directory hack? *goes off to search for that one*

lol
Reply With Quote
  #149  
Old 12-22-2001, 05:59 PM
Bedhead Bedhead is offline
 
Join Date: Oct 2001
Location: Canada
Posts: 55
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks the_sisko

Works great
Reply With Quote
  #150  
Old 12-22-2001, 06:32 PM
bira's Avatar
bira bira is offline
 
Join Date: Nov 2001
Posts: 387
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Sadie the Links Directory hack can be found at https://vborg.vbsupport.ru/showthrea...threadid=12815

You can see a demonstration of it on my BB:
http://www.atlasf1.com/bb/links.php
Reply With Quote
  #151  
Old 12-22-2001, 07:33 PM
Sadie Frost's Avatar
Sadie Frost Sadie Frost is offline
 
Join Date: Dec 2001
Location: Pittsburgh
Posts: 307
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks so much bira (that's a good one!)

Reply With Quote
Reply


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 01:38 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.04659 seconds
  • Memory Usage 2,340KB
  • Queries Executed 25 (?)
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
  • (4)bbcode_php
  • (1)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (2)pagenav_pagelinkrel
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)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_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