I have at least 1 user that I know of (who is on a dsl connection, I am not sure if that factors into it) who doesn't manually logout, and since I have my shoutbox set to refresh every 60 seconds, it is counting as an "action on the site", which keeps the user marked as online, forever.
I have the Who's Online avatar block installed, and I can watch the user moving around as if he were live on the site, and when I look at the tracker/page visits for the user, it shows, for every 60 seconds, this:
View Shouts
shoutbox/js/view
Is there:
a) a way to get this to stop happening, while still keeping my shoutbox set to refresh once per minute? And ..
b) a way to NOT have that logged in the tracker once per minute? It clogs up the tracker and I would also imagine the database.
TIA
Comments
Comment #1
disterics commentedhttp://drupal.org/node/247889 tracks the problem with shoutbox cloggging the tracker because of refreshes.
Not sure about it keeping the user logged in. I can't promise a fix in the next release but I will look around to see if it will be an easy fix.
Comment #2
AppleBag commentedThanks,
Well, I'm pretty sure this hack won't address the keeping the user logged in since it just filters out the Shout Views from the tracker, but it's a nice start. For anyone interested here is the modification I did to the Statistics.module (D5):
Search for this code (which should be on or around line 239):
just below it, add:
Then, below this line:
add the closing curly brace. }
The result is, it will show all other events, excluding the View Shouts event.
Comment #3
random4t4x14 commentedwill this hack work in d6?
Comment #4
burmistrow commented+1
what need to modify for cutout that messages from log in D6
Comment #5
AppleBag commentedSorry guys, I don't have D6 installed, so I can't take a look to see for myself.
Comment #6
burmistrow commentedThat what i understood.
AppleBag, you have changed statistics_user_tracker()
i have found the same code in D6 at file /modules/statistics/statistics.pages.inc
insert hack after line 52
while ($log = db_fetch_object($result)) {the code
anybody say me will that work, i'm newbee in drupal and php.
Comment #7
burmistrow commentederror too many ")" at the end, erase one of em and leave
But nothimg chage, View Shouts left in reports
Comment #8
liliplanet commentedsubscribe, thx
Comment #9
mstef commentedIs this something we want looked at for the 6.x branch?
Comment #10
liliplanet commenteddefinitely for 6.x thx !
Comment #11
mstef commentedIf anyone has a solution that doesn't involve hacking core, I'd love to know..
I noticed this annoying issue too..
Comment #12
jcisio commentedA solution is not to use Drupal menu system, but use a separate PHP file for the shoutbox update with a minimal db usage (include directly the Drupal settings.php, bypass all bootstrap process).
Comment #13
geerlingguy commentedAnother module that does this is Chatroom - there is a custom chatroom.php file that is hit, which allows a bypassing of core statistics/tracker, and for less db overhead when reading from the chat room table.
I would suggest Shoutbox take the same approach, for scalability...
Comment #14
geerlingguy commentedUpdating title, marked #247889: View Shouts in log! as a duplicate.
Comment #15
mstef commentedComment #16
momper commentedsubscribe
Comment #17
mstef commentedI don't think having a separate shout.php would work with how shoutbox is currently set up. Submodules depend on altering the ajax callback path, then using that path to determine group context, user context, etc. That wouldn't be possible with a separate php file.
Any ideas?
Comment #18
jcisio commentedWith one shoutbox.php you can have multiple paths: shoutbox.php?path=1 or shoutbox.php?path=2...
Comment #19
vitalblue commented