1

Topic: silent edit for users?

Ive searched and the only thing I saw was to make silent edit the default. Is it possible to make silent edit on for users? or is there a switch Im not seeing? right now admin has a box and users dont.

2

Re: silent edit for users?

you would have to edit viewtopic.php and remove the section that outputs the "last edited by..." part

Re: silent edit for users?

I would change edit.php to offer the checkbox and not update the edited time, then you won't need to change viewtopic.php.

See also: Edit Grace Period

Re: silent edit for users?

guardian34 wrote:

I would change edit.php to offer the checkbox and not update the edited time, then you won't need to change viewtopic.php.

See also: Edit Grace Period

I tried the Gracemod plug-in twice but it does not seem to work here.

I checked *very* carefully several times that I edited correctly according to the instructions... but still the same message appears "edited by". I'm using PunBB 1.2.14.

Re: silent edit for users?

It's by no means graceful, but...

comment or delete the following block of code from edit.php:

if ($is_admmod)
{
    if ((isset($_POST['form_sent']) && isset($_POST['silent'])) || !isset($_POST['form_sent']))
        $checkboxes[] = '<label><input type="checkbox" name="silent" value="1" tabindex="'.($cur_index++).'" checked="checked" /> '.$lang_post['Silent edit'];
    else
        $checkboxes[] = '<label><input type="checkbox" name="silent" value="1" tabindex="'.($cur_index++).'" /> '.$lang_post['Silent edit'];
}

comment out or remove the following line from viewtopic.php:

<?php if ($cur_post['edited'] != '') echo "\t\t\t\t\t".'<p class="postedit"><em>'.$lang_topic['Last edit'].' '.pun_htmlspecialchars($cur_post['edited_by']).' ('.format_time($cur_post['edited']).')</em></p>'."\n"; ?>

I believe that should work.

EDIT: oops, I misunderstood you. Ignore this.

Looking for a certain modification for your forum? Please take a look here before posting.

6 (edited by guardian34 2007-01-01 22:47)

Re: silent edit for users?

The Grace Period mod only works for a short time after the message has been posted.

Try this: http://wiki.punres.org/Silent_edit_for_users

Edit: Fixed URL

Re: silent edit for users?

guardian34 wrote:

The Grace Period mod only works for a short time after the message has been posted.

Try this: http://wiki.punres.org/Silent_edit_for_users

Edit: Fixed URL

Thanks, that can be handy.

However, I still want to use the functionality of Grace period. In my tests I tried editing about 15 seconds after the post was made. It was set to 1800 seconds grace period.

8 (edited by MadHatter 2007-01-03 20:56)

Re: silent edit for users?

edit the bit of code pogen posted and replace it w/ a hidden form element named silent w/ a value of 1 or edit the isadmmod if statement & comment out the if and braces.

Re: silent edit for users?

My mistake; Check out the mod readme now, I fixed something.

Re: silent edit for users?

guardian34 wrote:

My mistake; Check out the mod readme now, I fixed something.

Thank a lot, it works fine now.