aboutsummaryrefslogtreecommitdiffstats
path: root/packages/pure-ftpd.xml
diff options
context:
space:
mode:
Diffstat (limited to 'packages/pure-ftpd.xml')
-rw-r--r--packages/pure-ftpd.xml5
1 files changed, 3 insertions, 2 deletions
diff --git a/packages/pure-ftpd.xml b/packages/pure-ftpd.xml
index 6a873d79..3711829e 100644
--- a/packages/pure-ftpd.xml
+++ b/packages/pure-ftpd.xml
@@ -15,7 +15,7 @@
<adddeleteeditpagefields>
<columnitem>
<fielddescr>Username</fielddescr>
- <fieldname>graphname</fieldname>
+ <fieldname>username</fieldname>
</columnitem>
<columnitem>
<fielddescr>Description</fielddescr>
@@ -63,6 +63,7 @@
mwexec("/usr/bin/killall pure-ftpd");
</custom_deinstall_php_command>
<custom_add_php_command>
+ $expires = "";
if($_POST['expiration']) $expires = " -e " . $_POST['expiration'];
mwexec("/usr/sbin/pw useradd " . $_POST['username'] . $expires . " -m -k /home/ " . $_POST['username'] . " -s /usr/sbin/nologin");
$fd = popen("/usr/sbin/pw usermod -n " . $_POST['username'] . " -H 0", "w");
@@ -73,6 +74,6 @@
$savemsg = "User has been added.";
</custom_add_php_command>
<custom_delete_php_command>
- mwexec("/usr/sbin/pw userdel " . $_POST['username']);
+ system("/usr/sbin/pw userdel " . $username);
</custom_delete_php_command>
</packagegui>