vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB4 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=251)
-   -   How do you remove the "Report Post" link from just one forum? (https://vborg.vbsupport.ru/showthread.php?t=327346)

Falcon Capt 07-03-2019 01:38 AM

How do you remove the "Report Post" link from just one forum?
 
I tried using the template conditionals wrapped around the Report Post code in the Postbit Template, but it didn't work.
Quote:

Show is every forum but one: Remember to change x
Code:

Code:
<vb:if condition="$forum[forumid] != x">Show this if forum id is not x</vb:if>


I changed X to the forum number but it didn't work.

Code:

<vb:if condition="$forum[forumid] != 132"><vb:if condition="$show['reportlink']">
                                                <a class="report" href="{vb:raw post.reportlink}" rel="nofollow" title="{vb:rawphrase report_bad_post}"><!-- <img src="{vb:stylevar imgdir_button}/report-40b.png" alt="{vb:rawphrase report_bad_post}" /> -->&nbsp;</a> &nbsp;
                                        </vb:if></vb:if>


MarkFL 07-03-2019 02:01 AM

I would use a plugin rather than a template hack, and set the variable $show['reportlink'] to false if the forumid matches the desired where it should be turned off.

I have a product, whose latest version you can get here:

https://mathhelpboards.com/vbulletin...use-22022.html

The primary goal of this product is to discourage report abuse, but it can be configured to simply do what you want.

Falcon Capt 07-03-2019 02:32 AM

I don't need any of the other features and only need to shut of reports for a single forum, I would prefer to use a template hack/conditional versus installing an entire modification of which I only need one feature.

BetoPho 07-03-2019 08:32 AM

You should use
Code:

<vb:if condition="$thread['forumid'] != 132">
instead of $forum['forumid']. This variable won't work on postbit templates.

Also, check that you're inserting into the right postbit template.

Please know that if user try to manually use the report URL, it will work. That's why MarkFL advised you to use a plugin on this.

Falcon Capt 07-03-2019 02:55 PM

Quote:

Originally Posted by BetoPho (Post 2599708)
You should use
Code:

<vb:if condition="$thread['forumid'] != 132">
instead of $forum['forumid']. This variable won't work on postbit templates.

Also, check that you're inserting into the right postbit template.

Please know that if user try to manually use the report URL, it will work. That's why MarkFL advised you to use a plugin on this.

Perfect, that is exactly what I needed, worked great.

Thank you!


All times are GMT. The time now is 11:19 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.01164 seconds
  • Memory Usage 1,722KB
  • 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
  • (4)bbcode_code_printable
  • (2)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (5)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