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
Last 10 Searches Details »»
Last 10 Searches
Version: 1.00, by AntiOnline AntiOnline is offline
Developer Last Online: Jun 2004 Show Printable Version Email this Page

Version: 2.2.x Rating:
Released: 03-06-2002 Last Update: Never Installs: 156
 
No support by the author.

Greetings All:

Updated 3/11/2002: Hack now shows the date and time each search was made, plus the number of results. Also included is the security fix by firefly (thanks).

Updated 3/8/2002: It now also links those search words to the previous search results.

Here's just a little fun feature that I added for my users, and thought that I would share with everyone else. It works with versions 2.03 and up, requires no modifications to your database, and should take less than 2 minutes to install:

This hack displays the last 10 searches made by your users on your main site search page. It uses your censor options to make sure nothing naughty shows up (unless, that is, you want it to).

Demo at http://www.AntiOnline.com/search.php

Enjoy!

Yours In CyberSpace,
John Vranesevich
Founder, AntiOnline

Show Your Support

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

Comments
  #122  
Old 12-23-2002, 08:06 AM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by Squirre1
Hey FireFly, you might want to check me on this one...

I looked into this because I have not been able to see any searchs that I am performing


Are you searching with a regular user account?

Quote:
.. Based on the below quote from the MySQL manual:

If the search was performed by a guest which has an account value of "0", it tries to do the NOT IN which it can not compare to anything because that account does not exist in the user table...

I think this should be a correct query, I have tested here and it is working with no issues:

SELECT searchid,postids,dateline,querystring FROM search LEFT JOIN user USING (userid) WHERE querystring!="" AND (usergroupid NOT IN (5,6,7) OR search.userid = "0") ORDER BY searchid desc LIMIT 0,10
I guess I'm not sure why you would need to add the OR search.userid = "0" part. I'm not very good at mySQL, though.

Quote:
Also, as a note to some people, I had to upgrade my search.php in order the get the links created correctly so other users could access them. Otherwise, I got a user is not authorized message.

Enjoy this info folks.... !!
How did you upgrade? I am running 2.2.9 and it seems to work fine here.
Reply With Quote
  #123  
Old 12-23-2002, 11:18 AM
Squirre1 Squirre1 is offline
 
Join Date: Jan 2002
Posts: 4
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

When I say I had to upgrade... It was from the 2.2.6 Search.php to the 2.2.9 search.php... Also, the listings that did not get displayed were guest listing... Guests also have the option to search my forums and it was there searches that were not coming up in the last 10 searches list... BUT, registered users searches were...
Reply With Quote
  #124  
Old 12-24-2002, 11:37 PM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I see what you mean now. Their searches don't show on the listing, but they are still able to search. I like it the way it is now, though. I also allow them to search, but not be listed in the last 15 (I set it to that). Gives them more of an incentive to register.
Reply With Quote
  #125  
Old 12-25-2002, 09:11 PM
Da`Nacho Da`Nacho is offline
 
Join Date: Mar 2002
Location: Fort Worth, Texas
Posts: 45
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by User_001
Nice hack, Thanks.

And i don't think you want to have Mods and admins searches shown...unless there is a way of checking user permissions in the search(if the user is an admin or mod then it shows All post by the admin or mod). IMO, a serious flaw in security.
Just so everyone knows, I think this was fixed in vBulletin 2.2.8 so that permissions are checked before sending the user the search results. I've checked on my forum and search results matching threads said user doesn't have access to no longer seem to show up. As a result I have removed the 'not in 5,6,7' part of the hack on my forums and things are working peachy.
Reply With Quote
  #126  
Old 03-02-2003, 09:58 AM
mini2 mini2 is offline
 
Join Date: Nov 2001
Posts: 114
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by Da`Nacho


Just so everyone knows, I think this was fixed in vBulletin 2.2.8 so that permissions are checked before sending the user the search results. I've checked on my forum and search results matching threads said user doesn't have access to no longer seem to show up. As a result I have removed the 'not in 5,6,7' part of the hack on my forums and things are working peachy.
Just installed this hack, very cool. I'm addicted to vB hacking now!

www.mini2.com/forum/search.php

Is the above (regarding the 'bug fix') correct, is it safe to remove the 'not in 5,6,7' section of the query?
Reply With Quote
  #127  
Old 03-10-2003, 07:24 AM
Brother Brother is offline
 
Join Date: Sep 2002
Location: UAE
Posts: 12
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I use it in my version 2.3.0 and it works
Reply With Quote
  #128  
Old 03-10-2003, 04:29 PM
monstergamer's Avatar
monstergamer monstergamer is offline
 
Join Date: Feb 2003
Location: around the corner
Posts: 433
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

great hack
love it
clicks install
Reply With Quote
  #129  
Old 03-21-2003, 03:59 PM
Sweet Cheeks's Avatar
Sweet Cheeks Sweet Cheeks is offline
 
Join Date: Mar 2002
Location: Carson City, Nevada
Posts: 173
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
06-20-02 at 05:31 AM Kathy said this in Post #91
This is a great help to me. Thanks!

I'm wondering about making it possible for admin to see the users on this page? (Or have a page just for admin to see the searches?)
Yes I'd love this too, did anyone ever figure out how to do this?
Reply With Quote
  #130  
Old 03-22-2003, 03:30 AM
Snapperhaed Snapperhaed is offline
 
Join Date: Mar 2003
Location: Argentina
Posts: 32
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Nice hack! Thanks! Works fine on v2.3.3
Reply With Quote
  #131  
Old 03-24-2003, 03:01 PM
Brooke Brooke is offline
 
Join Date: Mar 2003
Posts: 1
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Easily installed on 2.3 release 3. Thanks!!
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 06:29 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.04827 seconds
  • Memory Usage 2,316KB
  • Queries Executed 27 (?)
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
  • (6)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
  • (1)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_postinfo_query
  • fetch_postinfo
  • 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