vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.6 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=194)
-   -   Recent Queries: From the Last 30 Days (https://vborg.vbsupport.ru/showthread.php?t=137185)

calorie 01-21-2007 10:00 PM

Recent Queries: From the Last 30 Days
 
This mod displays information about search queries from the last thirty days, starting from the day you install this mod. It does not include 'getnew' or 'getdaily' queries. The search ID link is active if you allow search sharing, the search was less than an hour ago, and the search has results. The IP address is resolvable like it is on the WOL page. The recent queries table created by this mod is in the same format as the vB search table, should you wish to make personal extensions to this mod. The number of results for the same query may vary, depending on how you set your vB permissions. See the screenshot.

Terminatoronly 01-22-2007 06:40 AM

cool i like it much so if a member search and i didnt see his search so i can know he wanted this so i go and post it :D thats awsem nice work installed and nominated :D and voted too :D

and first reply ;) with first install and nominate :D and vote too lol i think i am going crazy right now thats because of ur hack i like it much :D

SaN-DeeP 01-22-2007 06:52 AM

testing right now.. /me installs and nomiates this hack for motm

sensimilla 01-22-2007 07:07 AM

Great hack, useful!

Snake 01-22-2007 08:57 AM

Thanks! :D

TTG 01-22-2007 08:58 AM

Very useful addition.
Is it possible to clear the results once a month. I can imagine after a few months there could be pages of results !?

Clicked install.

FleaBag 01-22-2007 09:03 AM

I really like this too! I've tried for several incarnations of vB the "last X searches on search page" hack but it never seemed to pick up the searches correctly. Hopefully this one will play ball for me. Will install when I get home from work!

And THANK YOU. :)

[high]* FleaBag also nominates for MOTM.[/high]

Terminatoronly 01-22-2007 12:42 PM

Quote:

Originally Posted by TTG (Post 1164887)
Very useful addition.
Is it possible to clear the results once a month. I can imagine after a few months there could be pages of results !?

Clicked install.


i think you can from admincp (mantanience)

joeychgo 01-22-2007 01:53 PM

Love the idea. I have few suggestions --

First -- It looks like if someone clicks new posts that it records that. I see a few entries that are: Key Word(s): --- so im guessing thats what it is.

Second, I have a question. I have a few entries I see where it shows as guest but then gives a username under 'Query' - Is that someone searching for all posts by a user? If so - is this really necessary? Like 'New Posts' I dont know what value listing that search has.

Third - a running tally on how many times someone is searching a particular phrase might be helpful.

projectego 01-22-2007 04:23 PM

Very cool hack indeed... thanks, calorie!

JD45 01-22-2007 06:12 PM

/me installs

calorie 01-22-2007 08:43 PM

Thanks for the thanks, installs, ratings, and nominations. :D

@TTG: The mod automatically deletes from its table any entry over thirty days old.

@joeychgo: The 'getnew' and 'getdaily' searches should not be recorded. When members search, they can search on Key Word(s) and/or User Name. If one of those fields is blank, then dashes appear. That might be what you are seeing. Also, the Member column is who searched; the Query column contains what was searched. The other columns are there for additional information about the search.

Milad 01-23-2007 01:48 AM

This is nice, and may be used to show queries from last 30 days in clouds for forums that use fulltext search

Paul M 01-23-2007 02:30 AM

Nice.

Not if I'll use this yet, but it's a great idea so I've nominated anyway. :)

joeychgo 01-23-2007 12:18 PM

Quote:

Originally Posted by calorie (Post 1165288)

@joeychgo: The 'getnew' and 'getdaily' searches should not be recorded. When members search, they can search on Key Word(s) and/or User Name. If one of those fields is blank, then dashes appear. That might be what you are seeing. Also, the Member column is who searched; the Query column contains what was searched. The other columns are there for additional information about the search.

See attachment for what im talking about. It shows as 'guest' but a username is coming up under 'query'. But, if the search is not by a guest, then no username under 'query'.

NolF 01-24-2007 03:37 AM

thx for this hack pretty good one ^^ will help me see how cleaver my users are using the search function xD

calorie 01-24-2007 02:08 PM

Thanks again for the thanks, installs, ratings, and nominations. :)

@joeychgo: The Member column is who searched, and the Query column contains what was searched, i.e., the first row of your screenshot shows that Guest searched for Danny Boy, and the last two rows of your screenshot show that wenchupover searched for him/herself and then did another search for google analytics. Note that Guest could be a person or bot, and that when doing a search, it's possible to query on Key Word(s), User Name, or both.

MorrisMcD 01-24-2007 07:19 PM

Is it possible to restrict to only admins and/or mods?

calorie 01-25-2007 12:44 AM

In the recent_queries.php file find:
Code:

require_once('./global.php');
And afterwards add the following:
Code:

if (!is_member_of($vbulletin->userinfo, 5, 6, 7))
{
        exit();
}

Where 5, 6, 7 represents these groups:
Code:

5 : Super Moderators
6 : Administrators
7 : Moderators


stomph 01-25-2007 04:44 AM

Thanks for this, very useful!

When I imported the product, it didn't create the table 'rq_recent_queries'. I don't know why.. when I ran the SQL from the .xml file manually I got an error from MySQL. Maybe it's an old version (4.0.25)?

Well, I created the table manually and just copied the structure from the search-table over as that's what I assumed the SQL should have done.. then reimported the product and now it works! :)

MorrisMcD 01-25-2007 11:55 AM

Quote:

Originally Posted by calorie (Post 1166732)
In the recent_queries.php file find:
Code:

require_once('./global.php');
And afterwards add the following:
Code:

if (!is_member_of($vbulletin->userinfo, 5, 6, 7))
{
        exit();
}

Where 5, 6, 7 represents these groups:
Code:

5 : Super Moderators
6 : Administrators
7 : Moderators



Thanks!

htrshgytrs 01-31-2007 11:49 PM

Quote:

Originally Posted by Milad (Post 1165445)
This is nice, and may be used to show queries from last 30 days in clouds for forums that use fulltext search

I'd be keen to display the common searches in a cloud, how could this be done?

htrshgytrs 02-01-2007 12:29 AM

i used the cloud from here and altered the SQL to return common search terms in the cloud. Not pretty or too clever, but it works!

I changed this:

PHP Code:

$wordcloud_infos $db->query_read("
    SELECT SUM(score) AS f1, t2.title AS f2
    FROM " 
TABLE_PREFIX "postindex AS t1, " TABLE_PREFIX "word AS t2
    WHERE t1.wordid = t2.wordid GROUP BY t1.wordid ORDER BY f1 DESC LIMIT 100
"
); 

to this:

PHP Code:

$wordcloud_infos $db->query_read("
SELECT  count(query) AS f1, query AS f2
        FROM " 
TABLE_PREFIX "rq_recent_queries AS t1
        WHERE t1.sortby = 'lastpost' AND t1.searchuser = '' GROUP BY f2 ORDER BY
 f1 DESC LIMIT 100
"
); 


athlon64bit 04-01-2008 01:09 AM

Still working fine on version 3.6.9 just if anyone is wondering. I love this mod, being able to log search results or details should I say is very useful.
Thanks.:D

Boofo 04-01-2008 01:52 AM

I have guests allowed to search but when I do a search as a guest, it doesn't show up in the listing. I am using 3.7.0 RC1. Also, this doesn't record the search made in the drop down on the navbar. Shouldn't it pick that up to?

athlon64bit 04-30-2008 02:14 AM

Will this be made available for vb3.7? It is a brilliant mod. I hope so.


All times are GMT. The time now is 03:51 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.01468 seconds
  • Memory Usage 1,772KB
  • 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
  • (6)bbcode_code_printable
  • (2)bbcode_php_printable
  • (4)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (26)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
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete