diff --git a/plogical/applicationInstaller.py b/plogical/applicationInstaller.py index 2f12cab4c..49c7cf940 100755 --- a/plogical/applicationInstaller.py +++ b/plogical/applicationInstaller.py @@ -1748,7 +1748,6 @@ $parameters = array( pass - currentTemp = self.extraArgs['tempStatusPath'] self.extraArgs['tempStatusPath'] = "/home/cyberpanel/" + str(randint(1000, 9999)) self.extraArgs['SavedPlugins'] = SavedPlugins @@ -1778,10 +1777,15 @@ $parameters = array( webobj = Websites.objects.get(domain= self.extraArgs['domainName']) - path ="/home/%s/public_html"%(self.extraArgs['domainName']) - Finalurl = (self.extraArgs['domainName']) + if self.extraArgs['home'] == '0': + path = self.extraArgs['path'] + finalPath = "/home/" + self.extraArgs['domainName'] + "/public_html/" + path + "/" + Finalurl = f'{self.extraArgs["domainName"]}/{path}' + else: + finalPath = "/home/" + self.extraArgs['domainName'] + "/public_html/" + Finalurl = (self.extraArgs['domainName']) - wpobj = WPSites(owner=webobj, title=self.extraArgs['blogTitle'], path=path, FinalURL=Finalurl, + wpobj = WPSites(owner=webobj, title=self.extraArgs['blogTitle'], path=finalPath, FinalURL=Finalurl, AutoUpdates=(self.extraArgs['updates']), PluginUpdates=(self.extraArgs['Plugins']), ThemeUpdates=(self.extraArgs['Themes']),) wpobj.save() diff --git a/websiteFunctions/static/websiteFunctions/websiteFunctions.js b/websiteFunctions/static/websiteFunctions/websiteFunctions.js index 208f20400..65da4e2f2 100755 --- a/websiteFunctions/static/websiteFunctions/websiteFunctions.js +++ b/websiteFunctions/static/websiteFunctions/websiteFunctions.js @@ -289,6 +289,15 @@ app.controller('createWordpress', function ($scope, $http, $timeout, $compile, $ var autoupdates = $scope.autoupdates; var pluginupdates = $scope.pluginupdates; var themeupdates = $scope.themeupdates; + + var path = $scope.installPath; + + var home = "1"; + + if (typeof path != 'undefined') { + home = "0"; + } + var data = { title: WPtitle, @@ -303,6 +312,8 @@ app.controller('createWordpress', function ($scope, $http, $timeout, $compile, $ Themes: themeupdates, websiteOwner: websiteOwner, package: package, + home: home, + path: path, } var config = { headers: { diff --git a/websiteFunctions/templates/websiteFunctions/WPCreate.html b/websiteFunctions/templates/websiteFunctions/WPCreate.html index 86dd4f237..fe6c8e6ba 100644 --- a/websiteFunctions/templates/websiteFunctions/WPCreate.html +++ b/websiteFunctions/templates/websiteFunctions/WPCreate.html @@ -54,16 +54,40 @@ +{#