Quote:
Originally posted by Jawelin
How could make this hack automatically subscribe to the just replied thread if the user config has subscription enabled ?
Is the proper hidden var enough ?
Thanks
|
As asked in
Post #246 I put some addon to choose:
- subscribe to the thread (defaulted to 'no' in the original hack)
- add signature in quick-replied post (defaulted to 'yes' in the original hack)
Both are initially set to user's default values within UserCP:
In
showthread.php
PHP Code:
// replace :
$textareacols = gettextareawidth();
eval("\$replybox = \"".gettemplate('showthread_replybox')."\";");
// with :
$textareacols = gettextareawidth();
if (trim($bbuserinfo[signature])!= "") $signaturechecked="checked";
if ($bbuserinfo[emailnotification]!=0) $emailchecked="checked";
eval("\$replybox = \"".gettemplate('showthread_replybox')."\";");
In
showthread_quickreply template:
Code:
# remove two separate lines:
<input type="hidden" name="email" value="">
<input type="hidden" name="signature" value="yes">
# then add :
<td nowrap valign="bottom"><smallfont>
<input type="checkbox" name="email" value="yes" $emailchecked> Subscription<br>
<input type="checkbox" name="signature" value="yes" $signaturechecked> Signature<br>
<br> </smallfont></td>
# right after :
<smallfont><a href="javascript:checklength(document.vbform);">[check message length]</a><br><br></smallfont></td>
That's all, folks.
Thanks to FF for the great hack, again... but many users asked me such an enhancement.
Bye