| 1 | <mt:setvar name="page_title" value="<__trans phrase="Spam Settings">"> |
|---|
| 2 | <$mt:setvar name="position_actions_bottom" value="1"$> |
|---|
| 3 | <mt:setvar name="spam" value="1"> |
|---|
| 4 | <MTSetVarBlock name="system_msg"> |
|---|
| 5 | <mt:if name="error"> |
|---|
| 6 | <mtapp:statusmsg |
|---|
| 7 | id="generic-error" |
|---|
| 8 | class="error"> |
|---|
| 9 | <mt:var name="error"> |
|---|
| 10 | </mtapp:statusmsg> |
|---|
| 11 | </mt:if> |
|---|
| 12 | <mt:if name="saved"> |
|---|
| 13 | <mt:if name="can_rebuild"> |
|---|
| 14 | <mt:if name="need_full_rebuild"> |
|---|
| 15 | <mtapp:statusmsg |
|---|
| 16 | id="saved-full-rebuild" |
|---|
| 17 | class="success" |
|---|
| 18 | rebuild="all"> |
|---|
| 19 | <__trans phrase="Your spam preferences have been saved."> |
|---|
| 20 | </mtapp:statusmsg> |
|---|
| 21 | <mt:else> |
|---|
| 22 | <mt:if name="need_index_rebuild"> |
|---|
| 23 | <mtapp:statusmsg |
|---|
| 24 | id="saved-index-rebuild" |
|---|
| 25 | class="success" |
|---|
| 26 | rebuild="index"> |
|---|
| 27 | <__trans phrase="Your spam preferences have been saved."> |
|---|
| 28 | </mtapp:statusmsg> |
|---|
| 29 | <mtelse> |
|---|
| 30 | <mtapp:statusmsg |
|---|
| 31 | id="saved" |
|---|
| 32 | class="success"> |
|---|
| 33 | <__trans phrase="Your spam preferences have been saved."> |
|---|
| 34 | </mtapp:statusmsg> |
|---|
| 35 | </mt:if> |
|---|
| 36 | <mtelse> |
|---|
| 37 | <mtapp:statusmsg |
|---|
| 38 | id="saved" |
|---|
| 39 | class="success"> |
|---|
| 40 | <__trans phrase="Your spam preferences have been saved."> |
|---|
| 41 | </mtapp:statusmsg> |
|---|
| 42 | </mt:if> |
|---|
| 43 | <mtelse> |
|---|
| 44 | <mtapp:statusmsg |
|---|
| 45 | id="saved" |
|---|
| 46 | class="success"> |
|---|
| 47 | <__trans phrase="Your spam preferences have been saved."> |
|---|
| 48 | </mtapp:statusmsg> |
|---|
| 49 | </mtif> |
|---|
| 50 | </mt:if> |
|---|
| 51 | </MTSetVarBlock> |
|---|
| 52 | <MTSetVarBlock name="content_nav"> |
|---|
| 53 | <mt:include name="include/cfg_content_nav.tmpl"> |
|---|
| 54 | </MTSetVarBlock> |
|---|
| 55 | <mt:include name="include/header.tmpl"> |
|---|
| 56 | |
|---|
| 57 | <div id="cfg-spam"> |
|---|
| 58 | |
|---|
| 59 | <script type="text/javascript"> |
|---|
| 60 | /* <![CDATA[ */ |
|---|
| 61 | function scoreNudge(amount) { |
|---|
| 62 | var fld = getByID('junk_score_threshold'); |
|---|
| 63 | score = fld.value; |
|---|
| 64 | score.replace(/\+/, ''); |
|---|
| 65 | score = parseFloat(score) + amount; |
|---|
| 66 | if (isNaN(score)) score = amount; |
|---|
| 67 | if (score > 10) score = 10; |
|---|
| 68 | if (score < -10) score = -10; |
|---|
| 69 | if (score > 0) score = '+' + score; |
|---|
| 70 | fld.value = score; |
|---|
| 71 | return false; |
|---|
| 72 | } |
|---|
| 73 | /* ]]> */ |
|---|
| 74 | </script> |
|---|
| 75 | |
|---|
| 76 | <form name="cfg_form" method="post" action="<mt:var name="script_url">"> |
|---|
| 77 | <input type="hidden" name="id" value="<mt:var name="id">" /> |
|---|
| 78 | <input type="hidden" name="__mode" value="save" /> |
|---|
| 79 | <input type="hidden" name="_type" value="blog" /> |
|---|
| 80 | <input type="hidden" name="cfg_screen" value="cfg_spam" /> |
|---|
| 81 | <input type="hidden" name="blog_id" value="<mt:var name="blog_id">" /> |
|---|
| 82 | <input type="hidden" name="return_args" value="<mt:var name="return_args" escape="html">" /> |
|---|
| 83 | <input type="hidden" name="magic_token" value="<mt:var name="magic_token">" /> |
|---|
| 84 | |
|---|
| 85 | <mtapp:setting |
|---|
| 86 | id="auto_delete_junk" |
|---|
| 87 | label="<__trans phrase="Auto-Delete Spam">" |
|---|
| 88 | content_class="field-content-text" |
|---|
| 89 | help_page="blog_settings_feedback" |
|---|
| 90 | help_section="autodelete_junk"> |
|---|
| 91 | <input id="auto_delete_junk" name="auto_delete_junk" type="checkbox" value="1"<mt:if name="auto_delete_junk"> checked="checked"</mt:if> onclick="toggleSubPrefs(this)" class="cb" /> <span class="hint"><__trans phrase="If enabled, feedback reported as spam will be automatically erased after a number of days."></span></li> |
|---|
| 92 | </mtapp:setting> |
|---|
| 93 | |
|---|
| 94 | <div id="auto_delete_junk_prefs" <mt:unless name="auto_delete_junk">style="display: none"</mt:unless>> |
|---|
| 95 | <mtapp:setting |
|---|
| 96 | id="junk_folder_expiry" |
|---|
| 97 | label="<__trans phrase="Delete Spam After">" |
|---|
| 98 | hint="<__trans phrase="When an item has been reported as spam for this many days, it is automatically deleted.">" |
|---|
| 99 | help_page="blog_settings_feedback" |
|---|
| 100 | help_section="delete_junk_after"> |
|---|
| 101 | <input type="text" id="junk_folder_expiry" name="junk_folder_expiry" value="<mt:var name="junk_folder_expiry">" size="5" /> <__trans phrase="days"> |
|---|
| 102 | </mtapp:setting> |
|---|
| 103 | </div> |
|---|
| 104 | |
|---|
| 105 | <mtapp:setting |
|---|
| 106 | id="junk_score_threshold" |
|---|
| 107 | label="<__trans phrase="Spam Score Threshold">" |
|---|
| 108 | hint="<__trans phrase="Comments and TrackBacks receive a spam score between -10 (complete spam) and +10 (not spam). Feedback with a score which is lower than the threshold shown above will be reported as spam.">" |
|---|
| 109 | help_page="blog_settings_feedback" |
|---|
| 110 | help_section="junk_score_threshold"> |
|---|
| 111 | <a href="javascript:void(0)" id="decrease-threshold" onclick="return scoreNudge(-1)"><__trans phrase="Less Aggressive"> <img src="<mt:var name="static_uri">images/decrease.gif" alt="<__trans phrase="Decrease">" width="12" height="8" /></a> |
|---|
| 112 | <input type="text" id="junk_score_threshold" name="junk_score_threshold" value="<mt:var name="junk_score_threshold">" size="3" style="text-align: center" /> |
|---|
| 113 | <a href="javascript:void(0)" id="increase-threshold" onclick="return scoreNudge(1)"><img src="<mt:var name="static_uri">images/increase.gif" alt="<__trans phrase="Increase">" width="12" height="8" /> <__trans phrase="More Aggressive"></a> |
|---|
| 114 | </mtapp:setting> |
|---|
| 115 | |
|---|
| 116 | <mt:setvarblock name="action_buttons"> |
|---|
| 117 | <button |
|---|
| 118 | type="submit" |
|---|
| 119 | accesskey="s" |
|---|
| 120 | title="<__trans phrase="Save changes to these settings (s)">" |
|---|
| 121 | class="primary-button" |
|---|
| 122 | ><__trans phrase="Save Changes"></button> |
|---|
| 123 | </mt:setvarblock> |
|---|
| 124 | <mt:include name="include/actions_bar.tmpl" bar_position="bottom" hide_pager="1" settings_bar="1"> |
|---|
| 125 | |
|---|
| 126 | </form> |
|---|
| 127 | |
|---|
| 128 | </div> |
|---|
| 129 | |
|---|
| 130 | <mt:include name="include/footer.tmpl"> |
|---|