vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.7 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=228)
-   -   Miscellaneous Hacks - Activity Modification (https://vborg.vbsupport.ru/showthread.php?t=177366)

BigJohnny 03-10-2009 11:00 AM

Quote:

Originally Posted by vbboarder (Post 1759651)
Thanks for this cool mod! Features Request:

1. Enable finding today's activity in postbit for specific usergroups. This would be allow only special groups (ie: VIPs) to have their activity calculated so the # of extra queries in showthread would be limited.

2. Display Visit Activity% and Post Activity% in the Activity Statistics page.

3. Enable activity points to be given for profile visitor messages and social group messages, and display activity %'s for them in the statistics page.

I have to second these ideas..... that would be great if it could be done.

Quote:

Originally Posted by WetWired (Post 1762704)
I suppose you could wrap it in
Code:

<div style="border:1px solid black"></div>

You should also be able to just use:
Code:

<div class="info">code</div>
I think vbulletin has that setup by default, and it will add a box around stuff in the postbit.

I could be wrong though, i might just have it defined due to my styles.

vidan 03-13-2009 02:02 PM

i got Warning: unserialize() expects parameter 1 to be string, array given in [path]/index.php(67) : eval()'d code on line 21 in index.php?do=activitystat
im using 3.8.1 pl1

anyone got the same message too?

RTMdotORG 03-29-2009 04:01 PM

todays activity only works for my username...everyone elses is not moving up, and ideas?

WetWired 03-31-2009 01:10 AM

It's off by default because it brings a large load increase. You need to enable "Find today's activity for all users"

luckid 04-03-2009 03:06 PM

On profile user not appare location but only: Current Activity: Viewing home page :confused:

This error on: VB 3.81 and 3.82

Tnx in advance for you reply ;)

WetWired 04-08-2009 12:23 PM

I'm not sure I understand. You're saying that when a user is viewing a user profile that they show as viewing the home page on the who's online?

Are you sure this mod is responsible? I don't do anything that should effect the locations there.

Also note that it will display that location when the location isn't known, such as when an AJAX script or dynamic image script runs if it isn't properly setup not to show in the who's online. Since AJAX scripts and images are loaded after the main page, these would clobber the location.

Silver Tiger 04-14-2009 04:10 PM

I installed it, but I can't get the images to show up. I see the stuff in the post bit, but the images don't show up.

WetWired 04-15-2009 03:33 AM

Did you put the images in the correct place? It's a different place for each style. Right click the broken image and get the path where the browser is looking from the properties. That should help you figure out where the images belong.

robby-gr 04-28-2009 09:08 AM

Hello I need a help if someone have the experience of this happen.
When I am pressing stats on the navbar I am getting this error on the top of the statistic page:
Warning: unserialize() expects parameter 1 to be string, array given in [path]/index.php(67) : eval()'d code on line 79
I am appreciated for any idea or help
Thanks
Robby-gr

WetWired 04-28-2009 11:32 AM

Are you using the default datastore code, or are you using memcache or another alternative?
What vB version are you using?

robby-gr 04-28-2009 11:48 AM

Hello WetWired thanks for reply me.
I use VB3.8.2 and xcache and you have right!! I disabled the vB_Datastore_XCache and came back to vbulletin default vB_Datastore_Filecache and now is working ok.
But if you know (neither no):) a way to work with xcache too I will appreciated you, so much.
With respect
Robby

EmilGH 05-03-2009 03:51 PM

Hey -- GREAT mod -- it's become the lifeblood of a site I co-run. Two quick questions:

1. Is there a way to modify the "Top Activity" page to show last login instead of join date?

2. Is there a way to modify the "Top Activity" page to hide banned users (or users that are in a specific usergroup)?

We have an activity-based site, and when people fall below a certain activity level they get put into an inactive group. I'd like to be able to hide those folks from the top activity page so we see only the actives.

Thanks!

dbirosel 05-03-2009 07:43 PM

Is this compatible with v3.8 yet? I would love to use this mod.

WetWired 05-04-2009 04:38 AM

Quote:

Originally Posted by EmilGH (Post 1803716)
Hey -- GREAT mod -- it's become the lifeblood of a site I co-run. Two quick questions:

1. Is there a way to modify the "Top Activity" page to show last login instead of join date?

2. Is there a way to modify the "Top Activity" page to hide banned users (or users that are in a specific usergroup)?

We have an activity-based site, and when people fall below a certain activity level they get put into an inactive group. I'd like to be able to hide those folks from the top activity page so we see only the actives.

Thanks!

The problem with mucking with the top activity is that when you do it, the optimization to prevent checking everyone's activity breaks... since you are interested in the activity of a limited group of people, perhaps that is something you can deal with.

in the plugin marked "Top Activity" (for forumhome), find
Code:

  //****************************************
  // How old are we? how many users do we need to process?
  if(MAX_NUM==0){
    $querylimit=1;
  }else{//(MAX_NUM==0)
    $daysold=($WWU002startOfDay-$statdata[0])/WWU002_ONE_DAY;
    if(($daysold>=($vbulletin->options['WWU002weeks']*3.5))||($_REQUEST['oldway'])){
      //A complete reversal of activity is possible in this time period, we must check everyone
      $querylimit='1';
    }else{//($daysold>=($vbulletin->options['WWU002weeks']*3.5))
      //What is the lowest activity that could surpass the lowest activity on the old list?
      $acc=0;
      DEVDEBUG('Days old='.$daysold);
      for($i=1;$i<=$daysold;$i++){
        $acc+=$WWU002maxDay*$WWU002weekWeights[floor($i/7)];
      }//endfor($i=1;$i<$daysold;$i++)
      $temp=$statdata[1];
      $temp=array_pop($temp);
      DEVDEBUG('Activity lower limit='.$temp[3].'-'.($acc*2).'='.($temp[3]-($acc*2)));
      $acc=$temp[3]-($acc*2);
      if($acc<=0){
        //just use the simple where clause
        $querylimit='1';
      }else{//($acc<=0)
        $querylimit='wwu002activity>='.$acc;
      }//endif($acc<=0)
    }//endif($daysold>=($vbulletin->options['WWU002weeks']*3.5))
  }//endif(MAX_NUM==0)

replace with
Code:

$querylimit='usergroupid<>100';
This should (I'm not testing any of this) remove the optimization and instead only include people whose primary group is not group 100.

For the date thing, I think you should be able to
find (in the same plugin)
Code:

$longresult=$db->query_read('SELECT userid,username,joindate FROM '.TABLE_PREFIX.'user WHERE userid IN ('.$ids.')');
and replace with
Code:

$longresult=$db->query_read('SELECT userid,username,lastvisit AS joindate FROM '.TABLE_PREFIX.'user WHERE userid IN ('.$ids.')');

WetWired 05-04-2009 04:39 AM

Quote:

Originally Posted by dbirosel (Post 1803867)
Is this compatible with v3.8 yet? I would love to use this mod.

It's my understanding that it is.

robby-gr 05-04-2009 06:22 AM

Hello WetWired can you drop me one line answer?

I use VB3.8.2 and xcache and you have right!! I disabled the vB_Datastore_XCache and came back to vbulletin default vB_Datastore_Filecache and now is working ok.
But if you know (neither no) a way to work with xcache too I will appreciated you, so much.
With respect
Robby

WetWired 05-04-2009 01:34 PM

I don't know anything about xcache or why it messes up the top activity caching. The error you gave was related to the datastore, so that was the prime suspect. TBH, if you're getting that error I'm not sure how anything can work on your forum, since everything uses the datastore. The top activity uses it in a non-standard way, though, since the usual way would require a separate file for the top activity page.

There are two relatively easy ways to solve the problem:
  1. Don't cache the top activity information This is a very simple edit, but probably not one you'd want to make, as you'd be re-calculating the activity for the entire forum with each view.
  2. Roll the updates back into the standalone file version While straight forward, this would still take some time to do. Ideally, this would include changes to the rest of the mod to allow the administrator to choose whether or not to use the external file.

The third option would be to find out what xcache is doing, but as I said I know nothing about it.

robby-gr 05-05-2009 01:37 PM

Hello WetWired thanks for your answering me.
I understud these you wrote me.
I dont have other problems using xcache, datastore is working ok.
I will search and make some other combinations to find a way to work with xcache without this message on the top of page, I hope to find an answer :)
I like your mod very much, is good clever and clean job.
Thanks a lot.
Robby

EmilGH 05-05-2009 03:49 PM

Quote:

Originally Posted by WetWired (Post 1804115)
The problem with mucking with the top activity is that when you do it, the optimization to prevent checking everyone's activity breaks... since you are interested in the activity of a limited group of people, perhaps that is something you can deal with.

in the plugin marked "Top Activity" (for forumhome), find
Code:

  //****************************************
  // How old are we? how many users do we need to process?
  if(MAX_NUM==0){
    $querylimit=1;
  }else{//(MAX_NUM==0)
    $daysold=($WWU002startOfDay-$statdata[0])/WWU002_ONE_DAY;
    if(($daysold>=($vbulletin->options['WWU002weeks']*3.5))||($_REQUEST['oldway'])){
      //A complete reversal of activity is possible in this time period, we must check everyone
      $querylimit='1';
    }else{//($daysold>=($vbulletin->options['WWU002weeks']*3.5))
      //What is the lowest activity that could surpass the lowest activity on the old list?
      $acc=0;
      DEVDEBUG('Days old='.$daysold);
      for($i=1;$i<=$daysold;$i++){
        $acc+=$WWU002maxDay*$WWU002weekWeights[floor($i/7)];
      }//endfor($i=1;$i<$daysold;$i++)
      $temp=$statdata[1];
      $temp=array_pop($temp);
      DEVDEBUG('Activity lower limit='.$temp[3].'-'.($acc*2).'='.($temp[3]-($acc*2)));
      $acc=$temp[3]-($acc*2);
      if($acc<=0){
        //just use the simple where clause
        $querylimit='1';
      }else{//($acc<=0)
        $querylimit='wwu002activity>='.$acc;
      }//endif($acc<=0)
    }//endif($daysold>=($vbulletin->options['WWU002weeks']*3.5))
  }//endif(MAX_NUM==0)

replace with
Code:

$querylimit='usergroupid<>100';
This should (I'm not testing any of this) remove the optimization and instead only include people whose primary group is not group 100.

For the date thing, I think you should be able to
find (in the same plugin)
Code:

$longresult=$db->query_read('SELECT userid,username,joindate FROM '.TABLE_PREFIX.'user WHERE userid IN ('.$ids.')');
and replace with
Code:

$longresult=$db->query_read('SELECT userid,username,lastvisit AS joindate FROM '.TABLE_PREFIX.'user WHERE userid IN ('.$ids.')');

All worked perfectly -- thanks!!!

WetWired 05-06-2009 03:42 AM

Quote:

Originally Posted by robby-gr (Post 1805026)
Hello WetWired thanks for your answering me.
I understud these you wrote me.
I dont have other problems using xcache, datastore is working ok.
I will search and make some other combinations to find a way to work with xcache without this message on the top of page, I hope to find an answer :)
I like your mod very much, is good clever and clean job.
Thanks a lot.
Robby

Try this:
Upload the attached file to your forum directory and access activitystat.php with xcache on. See if it works without giving an error message. If it doesn't give an error message, I will follow up with the template changes to integrate it propperly.

lav0s 05-09-2009 04:28 PM

any chance we see this mod as a 3.8 mod??

WetWired 05-09-2009 11:17 PM

From what I'm told, it works fine with 3.8.

hinomaru 05-12-2009 03:07 AM

hello Wetwired,

i have the different show statistic of "Today Activity" between member list page and showtrhread page...
At the memberlist page,the "Today activity" Show zero bar...but at the showthread page show 1 bar...
What wrong with my setting?

WetWired 05-12-2009 11:20 AM

You must manually enable showing activity for each location in the Activity Display settings page.

algert 06-12-2009 09:23 AM

Can you give me the link of the activity page, as I just changed my forum's theme, and its not showing on the nav bar anymore, so i suppose i think i should add it manually.. in the navbar templates.

Thanks

Edited:- anyway got it fixed. thanks

mallutribes 07-09-2009 06:08 PM

Installed and working... but there is a problem with me..

How can change color of texts Activity, longetivity, Today & Posts.. since my back ground is white. i need to change this to black or something..

WetWired 07-13-2009 12:20 PM

Quote:

Originally Posted by mallutribes (Post 1845926)
Installed and working... but there is a problem with me..

How can change color of texts Activity, longetivity, Today & Posts.. since my back ground is white. i need to change this to black or something..

You used the wrong set of images. There is one for dark backgrounds and one for light backgrounds.

alexan1252 07-20-2009 03:50 PM

can somebody tell me, where i upload the folders light and dark please?

i dont know where's it

WetWired 07-22-2009 04:51 AM

Quote:

Originally Posted by Opening post
  • Why don't the images don't show up?/Why does the postcount have 's's in front of it?
    Be sure to upload one of the activity directories from activityimages.zip to the misc directory for each of your styles. To find a style's misc directory, goto the Style Manager, then from the dropdown next to the style, choose Stylevars. The setting Miscellaneous Images Folder contains the path to that style's misc directory, where you need to upload the activity directory

The location depends on (and is different for each) the style you are using. Follow the instructions above to find the correct location. Alternately, in most browsers, you can right click the missing image, choose properties, and it will tell you where it is looking, which will help you figure it out.

MrSir 07-24-2009 11:18 PM

i have this product running on 3.8.2...everything seems to be working, however no one is getting promoted after the initial calculation of stats b/c the stats are not updating. the cron is set for once an hour, and it has been installed for a few hours now. i have also tried to manually do the memberlevel promotions...but no luck.

i am running it for a contest, and set the start of board time at noon on thursday.

WetWired 07-25-2009 07:19 AM

The cron? There is no cron.

The stats update once a day. The amount that activity can rise in a day is limited; that's the point of this mod: you can't artificially raise the activity figure in one day, you must be continually active.

Also, the start of board time only effects longevity, which is how long a user has been a member compared to how long the forum has been arround.

Brathamike 07-26-2009 06:44 PM

Nice mod and thanks for answering everyones questions. Need more customer service like you..

Good job i like this mod works nice

Also how did you put your mod in the table that is shown on ur sig?

MrSir 07-27-2009 12:51 AM

thanks wetwired.

Brathamike 07-28-2009 04:14 AM

Hello i was wondering if this is correct. When i put my cursor over "Post" it dosent show post count it only shows a letter "s". Should this give me a post count?

spartan1123 08-03-2009 01:18 AM

Will this mod run in x3.8?

WetWired 08-03-2009 01:41 PM

Quote:

Originally Posted by Brathamike (Post 1856907)
Hello i was wondering if this is correct. When i put my cursor over "Post" it dosent show post count it only shows a letter "s". Should this give me a post count?

The postcount should be composed of several images, one for each digit. The alternate text for each image is the part of the image name that changes; spacer digits are indicated with "s". Originally, there was no tooltip, but some people complained about validation problems (in valid HTML, all images have alt attributes).

WetWired 08-03-2009 01:42 PM

Quote:

Originally Posted by spartan1123 (Post 1860447)
Will this mod run in x3.8?

Yes, it runs on vB3.8 with no known issues.

spartan1123 08-04-2009 12:48 PM

Quote:

Originally Posted by WetWired (Post 1860718)
Yes, it runs on vB3.8 with no known issues.

Good stuff, installed.

Zaki Shafqat 08-06-2009 06:19 PM

i didn't understand where to upload the images folder?

somebody help please

WetWired 08-07-2009 09:08 PM

Inside the zip file, there are two folders, "light" and "dark". You want to put the "activity" folder from the one that describes your site's style (light styles use the light folder) in the "misc" folder for the style that you are using. If you are using the default style, this would be forum/images/misc . Otherwise, it should be pretty easy to figure out by right clicking where the images should be in the postbit, going to properties, and looking at where the browser is trying to get the image; upload the activity folder in the place where the browser will find the images where it is looking.


All times are GMT. The time now is 04:22 PM.

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.01673 seconds
  • Memory Usage 1,848KB
  • 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
  • (10)bbcode_code_printable
  • (11)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)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