vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Modification Requests/Questions (Unpaid) (https://vborg.vbsupport.ru/forumdisplay.php?f=112)
-   -   Force comment when giving reputation (https://vborg.vbsupport.ru/showthread.php?t=65484)

northernstar 05-24-2004 04:18 PM

Force comment when giving reputation
 
Is there a way to force comments to be entered when someone gives/takes away your reputation? I find it annoying when someone takes away points and doesn't give reason.

ScottA 07-28-2004 01:41 PM

Well, I know I'm replying to a 2 month old post, but this came up in my search and I figured this might be helpful.

I wanted to know the same thing, but didn't find any instructions on how to do this. So I figured it out for myself.

Open reputation.php and look for the following:

PHP Code:

if ($_POST['do'] == 'addreputation'

Change that to:

PHP Code:

if ($_POST['do'] == 'addreputation' && strlen(trim($_POST['reason'])) > 0

Now if someone doesn't enter a comment the reputation will not be added. You may also want to edit the reputationbit template to note that.

Musicpill 07-28-2004 07:02 PM

Just so you dont get stuck on the editing reptuation window, heres a little help:

In your style/Styles open the template reputationbit and do the following (Just my example.)

Find
PHP Code:

[your_comments_on_this_post

In same line, after add
PHP Code:

<font size=1 color=red>*</font

Find

PHP Code:

<input type="text" class="bginput" size="40" maxlength="250" name="reason" />
                </
td>
            </
tr

Undeneith place
PHP Code:

<tr>
<
td>
<
font size=1 color=red>*Required</font>
</
td>
</
tr



Screenshot of that working:





:nervous:http://musicpill.com/websites/rep.gif

bi11i 09-28-2004 12:40 PM

hey, this is great - thanks for the answer to a question i've been searching on for quite awhile.

Jamie-UK 06-24-2005 06:53 PM

This is great, thank you.

Just one query... How can I not have a radio button selected, so that the user has to select either approve or disapprove when giving reputation ?

At the moment, positive reputation is always selected and this has led people to accidentally approve, when they meant to disapprove.

Regards.

Jamie

zylstra 10-17-2005 04:09 PM

I would guess in reputationbit change:
Code:

<div><label for="rb_reputation_pos"><input type="radio" name="reputation"
value="pos" id="rb_reputation_pos" checked="checked" />
$vbphrase[i_approve]</label></div>

to
Code:

<div><label for="rb_reputation_pos"><input type="radio" name="reputation"
value="pos" id="rb_reputation_pos" />
$vbphrase[i_approve]</label></div>


alfaowner 03-11-2006 05:19 PM

this didnt do the trick for v3.5.4 incase anyone wondered? It still submitted a vote even though neither box was selected.

BPnet 05-19-2006 02:03 AM

Great work!

Very helpful - thanks!

ballpnet 11-05-2007 11:04 PM

Apologies for the bump on an old thread. I've searched the forums for the most part and have yet to find a way to fully implement this feature for 3.6.8. The above hack works in the sense that no reputation gets added/deducted from a user. However, the reputation box just disappears without any notice if the user hits "Add to reputation."

Is there a way to tweak the javascript in the backend to validate the "Comments" field? Thank you very much for any assistance rendered.

Analogpoint 11-06-2007 06:21 PM

Have you seen this?

https://vborg.vbsupport.ru/showthread.php?t=123161


All times are GMT. The time now is 11:55 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.01839 seconds
  • Memory Usage 1,737KB
  • 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
  • (6)bbcode_php_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)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