mirror of
https://github.com/loewexy/pdnsmanager.git
synced 2025-01-16 03:02:22 +01:00
Disallowed user creating a new domain
This commit is contained in:
parent
ea9868f908
commit
1f59e8e87c
2 changed files with 6 additions and 1 deletions
|
@ -23,6 +23,11 @@ require_once '../lib/soa-mail.php';
|
|||
|
||||
$input = json_decode(file_get_contents('php://input'));
|
||||
|
||||
if(!isset($_SESSION['type']) || $_SESSION['type'] != "admin") {
|
||||
echo "Permission denied!";
|
||||
exit();
|
||||
}
|
||||
|
||||
if(isset($input->action) && $input->action == "addDomain") {
|
||||
$soaData = Array();
|
||||
$soaData[] = $input->primary;
|
||||
|
|
|
@ -84,7 +84,7 @@ limitations under the License.
|
|||
|
||||
</table>
|
||||
|
||||
<a class="btn btn-success" href="add-domain.php">Add</a>
|
||||
<?php if($_SESSION['type'] == "admin") echo '<a class="btn btn-success" href="add-domain.php">Add</a>'; ?>
|
||||
</div>
|
||||
|
||||
<div class="modal fade" id="deleteConfirm" tabindex="-1" role="dialog">
|
||||
|
|
Loading…
Reference in a new issue