diff --git a/dns/views.py b/dns/views.py index 64286a937..1a32bacbb 100644 --- a/dns/views.py +++ b/dns/views.py @@ -295,8 +295,6 @@ def getCurrentRecordsForDomain(request): records = Records.objects.filter(domain_id=domain.id) - json_data = "[" - checker = 0 fetchType = "" @@ -319,6 +317,9 @@ def getCurrentRecordsForDomain(request): elif currentSelection == 'srvRecord': fetchType = 'SRV' + json_data = "[" + checker = 0 + for items in records: if items.type == fetchType: diff --git a/static/images/icons/web-domain.png b/static/images/icons/web-domain.png new file mode 100644 index 000000000..37c5a0253 Binary files /dev/null and b/static/images/icons/web-domain.png differ diff --git a/static/websiteFunctions/websiteFunctions.js b/static/websiteFunctions/websiteFunctions.js index 0cd8d27ba..0b33e4b55 100644 --- a/static/websiteFunctions/websiteFunctions.js +++ b/static/websiteFunctions/websiteFunctions.js @@ -448,6 +448,7 @@ app.controller('websitePages', function($scope,$http) { }; $scope.fileManagerURL = "/filemanager/"+$("#domainNamePage").text(); + $scope.domainAliasURL = "/websites/"+$("#domainNamePage").text()+"/domainAlias"; $scope.previewUrl = "/preview/"+$("#domainNamePage").text()+"/"; var logType = 0; diff --git a/websiteFunctions/static/websiteFunctions/websiteFunctions.js b/websiteFunctions/static/websiteFunctions/websiteFunctions.js index 0cd8d27ba..5b1def704 100644 --- a/websiteFunctions/static/websiteFunctions/websiteFunctions.js +++ b/websiteFunctions/static/websiteFunctions/websiteFunctions.js @@ -448,6 +448,7 @@ app.controller('websitePages', function($scope,$http) { }; $scope.fileManagerURL = "/filemanager/"+$("#domainNamePage").text(); + $scope.domainAliasURL = "/websites/"+$("#domainNamePage").text()+"/domainAlias"; $scope.previewUrl = "/preview/"+$("#domainNamePage").text()+"/"; var logType = 0; @@ -2420,5 +2421,21 @@ app.controller('manageCronController', function($scope,$http) { }); +/* Java script code to manage cron ends here */ + + +/* Java script code to manage cron */ + +app.controller('manageAliasController', function($scope,$http) { + + $scope.aliasTable = false; + $scope.domainAliasForm = true; + $scope.aliasError = true; + $scope.couldNotConnect = true; + $scope.aliasCreated = true; + $scope.manageAliasLoading = true; + +}); + /* Java script code to manage cron ends here */ \ No newline at end of file diff --git a/websiteFunctions/templates/websiteFunctions/domainAlias.html b/websiteFunctions/templates/websiteFunctions/domainAlias.html new file mode 100644 index 000000000..c6ed170af --- /dev/null +++ b/websiteFunctions/templates/websiteFunctions/domainAlias.html @@ -0,0 +1,141 @@ +{% extends "baseTemplate/index.html" %} +{% load i18n %} +{% block title %}{% trans "Domain Aliases - CyberPanel" %}{% endblock %} +{% block content %} + +{% load static %} +{% get_current_language as LANGUAGE_CODE %} + + +
{% trans "With Domain Aliases you can visit example.com using example.net and view the same content." %}
+
+