The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
'Posts needing replies' widget
I'm using a PHP direct execution widget to find "Posts Needing Replies". These are defined as visible, non-sticky posts in a specific set of forums with 0 replies. But some of the forums are not available to all users, so I want to modify the query to hide any posts that are not accessible by the current user. Can anyone help?
PHP Code:
My problem is really just that I don't know how to get the id of the current user or a userinfo object from inside the PHP widget. I'm sure it's really simple, but I can't find an API for vb4... --------------- Added [DATE]1264368772[/DATE] at [TIME]1264368772[/TIME] --------------- Ok, after floundering a bit, this seems to work: vB::$vbulletin->userinfo['userid'] Please, anyone feel free to correct me if I'm making this harder than it needs to be... |
#2
|
|||
|
|||
OK, this seems to work!
PHP Code:
|
#3
|
|||
|
|||
Thanks for this, I was wondering how I might have them show up in a different order, from the most recent to the oldest.
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|