vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   Disabling attachments/uploads per forum (https://vborg.vbsupport.ru/showthread.php?t=225113)

TheGorf 10-12-2009 09:42 PM

Disabling attachments/uploads per forum
 
I've been spending a little time this afternoon with Google and the VB.org search trying to find a solution to my problem. I am running VB 3.8.4, and I would like to disable attachments per forum. I realize that I can do it globally, and I also realize that I can do it with usergroups, however here is my issue. We have many sub-forums that are protected by permissions based around usergroup membership. Some are assigned, some are open to anyone joining. The point is that I have a single forum that I have need to disable users from attaching images to posts, but still allow the use of the img tag to hotlink. I don't want to have to burden my admin and moderator staff with the chore of editing that one forums permissions for 40 usergroups and then update it every time we edit or create a new usergroup.

I found some stuff that might have done what I wanted, but it was for VB 3.5, and the searches I have done seem to come up with nothing but explanations about how to disable it using usergroups. I even took a hack at trying to do it with a plugin, but I just don't know enough about VB coding interfaces to be very productive.

Anyone have any good suggestions?

Seven Skins 10-12-2009 09:52 PM

Have you tried "Forum permission manager" in this you can disable "Can Upload Attachments"

EDIT: Oh you did ... ignore this.

.

Lynne 10-12-2009 11:20 PM

I would do it with a plugin. Set 'canpostattachment' to false. So, for the newreply page, I woud use the newreply_start hook location and do something like:

PHP Code:

if ($forumid == x)
$vbulletin->bf_ugp_forumpermissions['canpostattachment'] = false

x should be changed to the correct forumid. You can do something similar for other pages where attachments can be added (newthread.php page).

TheGorf 10-13-2009 05:57 PM

Quote:

Originally Posted by Lynne (Post 1898858)
I would do it with a plugin. Set 'canpostattachment' to false. So, for the newreply page, I woud use the newreply_start hook location and do something like:

PHP Code:

if ($forumid == x)
$vbulletin->bf_ugp_forumpermissions['canpostattachment'] = false

x should be changed to the correct forumid. You can do something similar for other pages where attachments can be added (newthread.php page).

That is exactly what I was looking for and it works perfectly! Thank you so much!


All times are GMT. The time now is 01:05 AM.

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.01753 seconds
  • Memory Usage 1,725KB
  • 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
  • (2)bbcode_php_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (4)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