vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB4 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=251)
-   -   Create posts but not threads (https://vborg.vbsupport.ru/showthread.php?t=294738)

Zuiq 02-03-2013 08:03 PM

Create posts but not threads
 
Is it possible to allow members to create posts but not threads?

We are using a forms mod that posts to a section which we don't want people to open new threads in, but we want them to reply to the forms.

Digital Jedi 02-03-2013 08:44 PM

I use a similar forms modification. What I did was add an if conditional (my favorite suggestion today, apparently) to the New Thread button which will instead show a link to starting a new form when in that forum, rather than the New Thread button. You need the vB4 specific conditionals for this (I did this on vB3), but if you can look them up and replace them, you can do something similar. This is in your FORUMDISPLAY template. The red parts are the parts I added:

Code:

<if condition="$show['newthreadlink']">
<if condition="$forumid == 3">
    <a href="misc.php?$session[sessionurl]do=form&amp;fid=1" rel="nofollow" style="font-size:13px">New Form</a>
<else />

<a href="newthread.php?$session[sessionurl]do=newthread&amp;f=$foruminfo[forumid]" rel="nofollow"><img src="$stylevar[imgdir_button]/newthread.gif" alt="$vbphrase[post_new_thread]" border="0" /></a>
</if>
<else />&nbsp;</if>

3 is the forum ID where my forms are submitted. I used a text link because I didn't have time to make a new image at the time. But you can use whatever you want. A button, a link, or nothing.

squidsk 02-04-2013 06:39 PM

Quote:

Originally Posted by Digital Jedi (Post 2401687)
I use a similar forms modification. What I did was add an if conditional (my favorite suggestion today, apparently) to the New Thread button which will instead show a link to starting a new form when in that forum, rather than the New Thread button. You need the vB4 specific conditionals for this (I did this on vB3), but if you can look them up and replace them, you can do something similar. This is in your FORUMDISPLAY template. The red parts are the parts I added:

Code:

<if condition="$show['newthreadlink']">
<if condition="$forumid == 3">
    <a href="misc.php?$session[sessionurl]do=form&amp;fid=1" rel="nofollow" style="font-size:13px">New Form</a>
<else />

<a href="newthread.php?$session[sessionurl]do=newthread&amp;f=$foruminfo[forumid]" rel="nofollow"><img src="$stylevar[imgdir_button]/newthread.gif" alt="$vbphrase[post_new_thread]" border="0" /></a>
</if>
<else />&nbsp;</if>

3 is the forum ID where my forms are submitted. I used a text link because I didn't have time to make a new image at the time. But you can use whatever you want. A button, a link, or nothing.

Wouldn't it be easier to just edit the permissions for the relevant user group(s) for that particular forum as follows:
  1. Turn off Can Post Threads
  2. Turn on Can Reply to Others' Threads

Digital Jedi 02-04-2013 06:48 PM

Quote:

Originally Posted by squidsk (Post 2401887)
Wouldn't it be easier to just edit the permissions for the relevant user group(s) for that particular forum as follows:
  1. Turn off Can Post Threads
  2. Turn on Can Reply to Others' Threads

It depends on how the forms modification works. Unless it somehow bypasses posting permissions, you would need permissions to be turned on to allow the form to be posted as a thread to that forum in the first place. Only other way that would work is if the users replying to those threads just so happen to be in a different usergroup than the people allowed to fill out the forms and start those threads. But odds are, you'd still new the New Thread posting permissions to stay intact.


All times are GMT. The time now is 04:22 PM.

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.03063 seconds
  • Memory Usage 1,724KB
  • 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_code_printable
  • (2)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