Register Members List Search Today's Posts Mark Forums Read

Reply
 
Thread Tools
  #1  
Old 05 Mar 2017, 16:58
Mickie D Mickie D is offline
 
Join Date: Jun 2002
Looking for a variable - threadid

I am writing a small log script that will eventually give me details on threads that are read over a day, week, month.

I want to know who is reading what so we can make decisions based on this information.

Anyway, I have almost all the data I want to collect on SHOWTHREAD COMPLETE plugin hook (i think that is the right location).

I am guessing/hoping that I can use


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Is that correct, without the need to select the information from the database

I know I can use


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

also is there a list of these globals anywhere?

--------------- Added 05 Mar 2017 at 17:35 ---------------

Found it

$vbulletin->GPC['threadid']
__________________
Digitalworldz Satellite Cable TV Forums
Cable, Satellite, Consoles, Mobile Phones, Audio Visual, and general chat

Last edited by Mickie D; 05 Mar 2017 at 17:35.
Reply With Quote
  #2  
Old 05 Mar 2017, 19:06
Dave Dave is offline
 
Join Date: Jun 2010
Real name: Dave
You can also use $threadid and $thread['threadid'], I would personally use these variables instead of $vbulletin->GPC['threadid'].
__________________
https://technidev.com - security, development, exploits, vBulletin
dave[at]technidev[dot]com

Contact me for custom vBulletin 3/4 work & server/website management.
Reply With Quote
  #3  
Old 08 Mar 2017, 09:13
Mickie D Mickie D is offline
 
Join Date: Jun 2002
Dave, It would not let me use the Like button again on you lol.

So thank you very much.

Can I ask why you prefer those over the one I found; is there more process power used, or a security issue???

Thanks again Dave.
__________________
Digitalworldz Satellite Cable TV Forums
Cable, Satellite, Consoles, Mobile Phones, Audio Visual, and general chat
Reply With Quote
  #4  
Old 08 Mar 2017, 14:40
Dave Dave is offline
 
Join Date: Jun 2010
Real name: Dave
$threadid and $thread['threadid'] are pulled from the database and $vbulletin->GPC['threadid'] is a variable (but cast to an integer) that is supplied by the client.

Security wise there's no risk, for readability I would use $threadid though.
__________________
https://technidev.com - security, development, exploits, vBulletin
dave[at]technidev[dot]com

Contact me for custom vBulletin 3/4 work & server/website management.
Reply With Quote
  #5  
Old 08 Mar 2017, 15:38
Mickie D Mickie D is offline
 
Join Date: Jun 2002
Thank you Dave.

Mick
__________________
Digitalworldz Satellite Cable TV Forums
Cable, Satellite, Consoles, Mobile Phones, Audio Visual, and general chat
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

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


New To Site? Need Help?

All times are GMT. The time now is 09:00.

Layout Options | Width: Wide Color: