Image Preview:
File name: Topic Box Moderation
Author: Daemon
Functionality: Al Versions
Details:
First go to your
Administration Panel → Modules →Html & Javascript Management → Javascript Management
Name: Topic Box Moderation
Placement: In the Topics
File name: Topic Box Moderation
Author: Daemon
Functionality: Al Versions
Details:
First go to your
Administration Panel → Modules →Html & Javascript Management → Javascript Management
Name: Topic Box Moderation
Placement: In the Topics
- Cod:
$(document).ready(function(){
if($('#stats:last a[href*="/modcp?"]').length){
$('#quick_reply input[value="Preview"]').before('<input type="button" value="Box Moderation" id="cdm" style="float: left;"/>');
$('input#cdm').toggle(function() {
$(this).after('
<div class="main-content" style="min-width: 428px;z-index: 2000;margin: 30px 0 8px 0;position: absolute;">
<div id="mod" style="background: #fff;padding: 3px;">
<select id="status" style="width: 50%">
<option value="">Status</option>
<option value="[size=14][color=green][b][i]Resolved topic; and Blocked[/i][/b][/color][/size]">Resolved topic; and Blocked</option>
<option value="[size=14][color=red][b][i]topic locked[/i][/b][/color][/size]">topic locked</option>
<option value="[size=14][color=green][b][i]topic unlocked[/i][/b][/color][/size]">topic unlocked</option>
</select>
<select id="to" style="width: 50%">
<option value="">moved to</option>
<option value="[b]moved to:[/b] Archives">Archives</option>
<option value="[b]moved to:[/b] dump">dump</option>
<option value="[b]moved to:[/b] corresponding location">corresponding location</option>
<option value="[b]moved to:[/b]Tips and Tutorials">Tips and Tutorials</option>
</select>
<textarea id="mot" name="subject" placeholder="Please specify the reason of this message" class="inputbox" style="display: block; margin: 5px 0 5px 0; min-height: 55px;" onChange="titulo();"></textarea>
<input onclick=" envia()" type="button" id="gerar-msg" value="Generate"/>
<input name="post" onclick=" envia()" type="submit" id="gerar-msg" value="Send"/>
<input name="post" onclick=" block()" type="submit" id="gerar-msg" value="send & Block"/>
<input type="button" value="Clear box" id="limpar-msg"/>
</div>
</div>');
}, function(){
$(this).next().remove();
});
$('#limpar-msg').click(function(){
$('#text_editor_textarea').sceditor('instance').val('');
});
}
});
function envia(){
if($('#text_editor_textarea').val() == ""){
var pegatopics = $('[name="t"]').val();
$('[name="t"]').val(pegatopics);
$('[name="message"]').last().sceditor('instance').insertText($('.sceditor-container iframe').val()+''+$("#status").val()+'\n'+$('#mot').val()+'\n'+$('#to').val());
}}
function block(){
if($('#text_editor_textarea').val() == ""){
var pegatopics = $('[name="t"]').val();
$('[name="t"]').val(pegatopics);
$('[name="message"]').last().sceditor('instance').insertText($('.sceditor-container iframe').val()+''+$("#status").val()+'\n'+$('#mot').val()+'\n'+$('#to').val());
window.open('/modcp?t='+pegatopics+'&mode=move&mode=lock');
}}