D7net
Home
Console
Upload
information
Create File
Create Folder
About
Tools
:
/
opt
/
psa
/
admin
/
plib
/
modules
/
galileo
/
resources
/
Filename :
addDomain.js
back
Copy
// Copyright 1999-2019. Plesk International GmbH. All rights reserved. function main() { var createdDomainKey = 'ghe-createdDomain'; window.localStorage.removeItem(createdDomainKey); var uat = Jsw && Jsw.UAT; var isRedirectedFromSetupScreen = document.referrer.match(/\/web\/setup/); if (!isRedirectedFromSetupScreen) { return; } if (window.location.href.match(/source=git/)) { uat && uat.dispatchAction('exp_add_domain_with_git'); var gitDeploymentCheckbox = document.getElementById('git-deploymentEnabled'); gitDeploymentCheckbox && gitDeploymentCheckbox.click(); } else if (window.location.href.match(/source=upload/)) { uat && uat.dispatchAction('exp_add_domain_with_fileupload'); var redirectToUpload = document.getElementById('addDomainUpload-redirectToUpload'); redirectToUpload.value = 'true'; var submitButton = document.getElementById('btn-send'); submitButton.addEventListener('click', function () { var domainNameInput = document.getElementById('domainName-name'); window.localStorage.setItem(createdDomainKey, domainNameInput.value); }); } else { if (PleskExt.Galileo.Config.showNewButtons) { uat && uat.dispatchAction('exp_add_domain'); } else { uat && uat.dispatchAction('exp_add_domain_default'); } } } main();