The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
How to get forumid in plugin
I would like to get the forumid from the upload_accept plugin hook. In vB3 I used:
$this->foruminfo['forumid'] but that no longer works in vB4. Does anyone know the proper variable that one could use to obtain the forumid from this hook? Thank you. |
#2
|
||||
|
||||
<a href="https://vborg.vbsupport.ru/showpost.php?p=1939297&postcount=81" target="_blank">https://vborg.vbsupport.ru/showp...7&postcount=81</a>
Have a look here. Once you get the variable, register it, then use it in your template. . |
#3
|
|||
|
|||
Quote:
Unfortunately a registered variable is only useful in the template you register it for. I need to be able to get the forumid when using the attachment manager. Looks like I'll need to set a cookie and do it that way. |
#4
|
||||
|
||||
Not every attachment has a forumid associated with it, so be careful to think through what you are trying to do.
|
#5
|
|||
|
|||
Quote:
I've come to the conclusion that vB4 has disassociated the forumid from the attachment and that is why I can't verify the forumid which makes perfect sense. My goal is to reject any uploads via the Attachment Manager that have a certain extension unless the upload is going to be in a certain forum. I think my only hope is to parse the post once it's been submitted and if there are any attachments that are of the wrong in the wrong forum I can then delete them. |
#6
|
|||
|
|||
to replace $this->foruminfo['forumid']
try this $this->$GLOBALS['forumid'] Good luck framer |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|