diff --git a/DnsServerCore/www/css/main.css b/DnsServerCore/www/css/main.css index 9c14d155..101fdc46 100644 --- a/DnsServerCore/www/css/main.css +++ b/DnsServerCore/www/css/main.css @@ -281,3 +281,8 @@ label { font-size: 12px; font-weight: bold; } + +.about p { + color: rgb(119, 119, 119); + text-align: center; +} diff --git a/DnsServerCore/www/img/logo.png b/DnsServerCore/www/img/logo.png new file mode 100644 index 00000000..1bdbde1a Binary files /dev/null and b/DnsServerCore/www/img/logo.png differ diff --git a/DnsServerCore/www/index.html b/DnsServerCore/www/index.html index 59fadf16..d1bcf05d 100644 --- a/DnsServerCore/www/index.html +++ b/DnsServerCore/www/index.html @@ -98,6 +98,7 @@ +
@@ -610,6 +611,8 @@
technitium.com
+ +
@@ -647,6 +650,8 @@
technitium.com
+ +
@@ -1084,9 +1089,36 @@
- - +
+
+ Technitium Logo +

Technitium DNS Server

+

Version

+

+ Copyright (C) 2019 Shreyas Zare (shreyas@technitium.com)
+ This program comes with ABSOLUTELY NO WARRANTY. This is free software, and you are welcome to redistribute it under certain conditions.
+

+

Source code available under GNU General Public License v3.0 on  GitHub

+ +

Contact

+

For support, send an email to support@technitium.com.

+

+ Follow @technitium on Twitter.
+ Checkout Technitium Blog. +

+ +

Become A Patron

+

Make contribution to Technitium by becoming a Patron and help making new software, updates, and features possible.

+

+ Become A Patron Now! +

+
+ +
+ + + @@ -1159,6 +1191,56 @@ + + + + \ No newline at end of file diff --git a/DnsServerCore/www/js/main.js b/DnsServerCore/www/js/main.js index 7fe7744e..2dccc8dc 100644 --- a/DnsServerCore/www/js/main.js +++ b/DnsServerCore/www/js/main.js @@ -510,6 +510,7 @@ function loadDnsSettings() { url: "/api/getDnsSettings?token=" + token, success: function (responseJSON) { document.title = "Technitium DNS Server " + responseJSON.response.version + " - " + responseJSON.response.serverDomain; + $("#lblAboutVersion").text(responseJSON.response.version); $("#txtServerDomain").val(responseJSON.response.serverDomain); $("#lblServerDomain").text(" - " + responseJSON.response.serverDomain); @@ -2761,3 +2762,103 @@ function deleteLog() { return false; } + +function resetImportAllowedZonesModal() { + + $("#divImportAllowedZonesAlert").html(""); + $("#txtImportAllowedZones").val(""); + + return false; +} + +function importAllowedZones() { + var divImportAllowedZonesAlert = $("#divImportAllowedZonesAlert"); + var allowedZones = cleanTextList($("#txtImportAllowedZones").val()); + + if ((allowedZones.length === 0) || (allowedZones === ",")) { + showAlert("warning", "Missing!", "Please enter allowed zones to import.", divImportAllowedZonesAlert); + return false; + } + + var btn = $("#btnImportAllowedZones").button('loading'); + + HTTPRequest({ + url: "/api/importAllowedZones?token=" + token, + data: "allowedZones=" + allowedZones, + success: function (responseJSON) { + $("#modalImportAllowedZones").modal("hide"); + btn.button('reset'); + + showAlert("success", "Imported!", "Domain names were imported to allowed zone successfully."); + }, + error: function () { + btn.button('reset'); + }, + invalidToken: function () { + btn.button('reset'); + showPageLogin(); + }, + objAlertPlaceholder: divImportAllowedZonesAlert + }); + + return false; +} + +function exportAllowedZones() { + + window.open("/api/exportAllowedZones?token=" + token, "_blank"); + + showAlert("success", "Exported!", "Allowed zones were exported successfully."); + + return false; +} + +function resetImportCustomBlockedZonesModal() { + + $("#divImportCustomBlockedZonesAlert").html(""); + $("#txtImportCustomBlockedZones").val(""); + + return false; +} + +function importCustomBlockedZones() { + var divImportCustomBlockedZonesAlert = $("#divImportCustomBlockedZonesAlert"); + var blockedZones = cleanTextList($("#txtImportCustomBlockedZones").val()); + + if ((blockedZones.length === 0) || (blockedZones === ",")) { + showAlert("warning", "Missing!", "Please enter custom blocked zones to import.", divImportCustomBlockedZonesAlert); + return false; + } + + var btn = $("#btnImportCustomBlockedZones").button('loading'); + + HTTPRequest({ + url: "/api/importCustomBlockedZones?token=" + token, + data: "blockedZones=" + blockedZones, + success: function (responseJSON) { + $("#modalImportCustomBlockedZones").modal("hide"); + btn.button('reset'); + + showAlert("success", "Imported!", "Domain names were imported to custom blocked zone successfully."); + }, + error: function () { + btn.button('reset'); + }, + invalidToken: function () { + btn.button('reset'); + showPageLogin(); + }, + objAlertPlaceholder: divImportCustomBlockedZonesAlert + }); + + return false; +} + +function exportCustomBlockedZones() { + + window.open("/api/exportCustomBlockedZones?token=" + token, "_blank"); + + showAlert("success", "Exported!", "Custom blocked zones were exported successfully."); + + return false; +} \ No newline at end of file