2 require_once "../common.php";
4 require_once "../header.php";
7 $ban_exceptions = $rpc->serverbanexception()->getAll();
10 <h4
>Ban Exceptions Overview
</h4
>
11 Here is where you can make an exception to bans
, that is
, to make it so that the target mask is exempt from the ban types you specify
.<br
>
14 <p
><button type
="button" class="btn btn-primary" data
-toggle
="modal" data
-target
="#myModal">
17 <div
class="modal fade" id
="myModal" tabindex
="-1" role
="dialog" aria
-labelledby
="confirmModalCenterTitle" aria
-hidden
="true">
18 <div
class="modal-dialog modal-dialog-centered" role
="document">
19 <div
class="modal-content">
20 <div
class="modal-header">
21 <h5
class="modal-title" id
="myModalLabel">Add
new Name Ban
</h5
>
22 <button type
="button" class="close" data
-dismiss
="modal" aria
-label
="Close">
23 <span aria
-hidden
="true">×
;</span
>
26 <div
class="modal-body">
29 <div
class="align_label">Nick
/ Channel
</div
> <input
class="curvy" type
="text" id
="tkl_add" name
="tkl_add"><br
>
31 <div
class="align_label"><label
for="banlen_w">Duration
: </label
></div
>
32 <select
class="curvy" name
="banlen_w" id
="banlen_w">
34 for ($i = 0; $i <= 56; $i++
)
37 echo "<option value=\"0w\"></option>";
40 $w = ($i == 1) ? "week" : "weeks";
41 echo "<option value=\"$i" . "w\"
>$i $w" . "</option>";
46 <select
class="curvy" name
="banlen_d" id
="banlen_d">
48 for ($i = 0; $i <= 31; $i++
)
51 echo "<option value=\"0d\"></option>";
54 $d = ($i == 1) ? "day" : "days";
55 echo "<option value=\"$i" . "d\"
>$i $d" . "</option>";
60 <select
class="curvy" name
="banlen_h" id
="banlen_h">
62 for ($i = 0; $i <= 24; $i++
)
65 echo "<option value=\"0d\"></option>";
68 $h = ($i == 1) ? "hour" : "hours";
69 echo "<option value=\"$i" . "h\"
>$i $h" . "</option>";
74 <br
><div
class="align_label"><label
for="ban_reason">Reason
: </label
></div
>
75 <input
class="curvy input_text" type
="text" id
="ban_reason" name
="ban_reason"><br
>
76 <input
class="curvy input_text" type
="checkbox" id
="soft" name
="soft">Don
't affect logged-in users (soft)
80 <div class="modal-footer">
81 <button id="CloseButton" type="button" class="btn btn-secondary" data-dismiss="modal">Cancel</button>
82 <button type="submit" action="post" class="btn btn-danger">Add Ban</button>
89 <table class="container-xxl table table-sm table-responsive caption-top table-striped">
90 <thead class="table-primary">
92 <th scope="col"><input type="checkbox" label='selectall
' onClick="toggle_tkl(this)" /></th>
93 <th scope="col">Mask</th>
94 <th scope="col">Duration</th>
95 <th scope="col">Reason</th>
96 <th scope="col">Set By</th>
97 <th scope="col">Set On</th>
98 <th scope="col">Expires</th>
102 foreach($ban_exceptions as $ban_exceptions)
104 $set_in_config = ((isset($ban_exceptions->set_in_config) && $ban_exceptions->set_in_config) || ($ban_exceptions->set_by == "-config-")) ? true : false;
105 echo "<tr scope='col
'>";
107 echo "<td scope=\"col\"></td>";
109 echo "<td scope=\"col\"><input type=\"checkbox\" value='" . base64_encode($ban_exceptions->name).",".base64_encode($ban_exceptions->type) . "' name=\"tklch[]\"></td>";
110 echo "<td scope=\"col\">".$ban_exceptions->name."</td>";
111 echo "<td scope=\"col\">".$ban_exceptions->duration_string."</td>";
112 echo "<td scope=\"col\">".$ban_exceptions->reason."</td>";
113 $set_by = $set_in_config ? "<span class=\"badge rounded-pill badge-secondary\">Config</span>" : show_nick_only($ban_exceptions->set_by);
114 echo "<td scope=\"col\">".$set_by."</td>";
115 echo "<td scope=\"col\">".$ban_exceptions->set_at_string."</td>";
116 echo "<td scope=\"col\">".$ban_exceptions->expire_at_string."</td>";
119 ?></tbody></table><p><button type="button" class="btn btn-danger" data-toggle="modal" data-target="#myModal2">
122 <div class="modal fade" id="myModal2" tabindex="-1" role="dialog" aria-labelledby="confirmModalCenterTitle" aria-hidden="true">
123 <div class="modal-dialog modal-dialog-centered" role="document">
124 <div class="modal-content">
125 <div class="modal-header">
126 <h5 class="modal-title" id="myModalLabel">Confirm deletion</h5>
127 <button type="button" class="close" data-dismiss="modal" aria-label="Close">
128 <span aria-hidden="true">×</span>
131 <div class="modal-body">
132 Are you sure you want to do this?<br>
133 This cannot be undone.
135 <div class="modal-footer">
136 <button id="CloseButton" type="button" class="btn btn-secondary" data-dismiss="modal">Cancel</button>
137 <button type="submit" action="post" class="btn btn-danger">Delete</button>
142 </div></form></div></div>
144 <?php require_once 'footer
.php
'; ?>