summaryrefslogtreecommitdiffstats
path: root/application/modules
diff options
context:
space:
mode:
Diffstat (limited to 'application/modules')
-rw-r--r--application/modules/dev/forms/BootmenuEntriesAdd.php12
-rw-r--r--application/modules/dev/forms/BootmenuEntriesEdit.php10
-rw-r--r--application/modules/dev/forms/BootosCreate.php2
-rw-r--r--application/modules/dev/forms/BootosEdit.php2
4 files changed, 18 insertions, 8 deletions
diff --git a/application/modules/dev/forms/BootmenuEntriesAdd.php b/application/modules/dev/forms/BootmenuEntriesAdd.php
index e849e2d..297a982 100644
--- a/application/modules/dev/forms/BootmenuEntriesAdd.php
+++ b/application/modules/dev/forms/BootmenuEntriesAdd.php
@@ -78,17 +78,21 @@ class dev_Form_BootmenuEntriesAdd extends Zend_Form
));
}
-
+ if($_POST['kclactive'])
+ $kcllength = 175 - strlen($this->bootoslist[$_POST['bootosID']]->getDefaultkcl());
+ else
+ $kcllength = 175;
+
$this->addElement('textarea', 'kclappend', array(
'filters' => array('StringTrim'),
'validators' => array(
- array('StringLength', false, array(0, 50)),
+ array('StringLength', false, array(0, $kcllength)),
),
'required' => false,
'cols' => 50,
'rows' => 5,
- 'label' => 'KCL-Append:'
-
+ 'label' => 'KCL-Append:',
+ 'description' => 'Chars left: ' . $kcllength
));
$defaultconfigid = $this->bootoslist[$_POST['bootosID']]->getConfigID();
diff --git a/application/modules/dev/forms/BootmenuEntriesEdit.php b/application/modules/dev/forms/BootmenuEntriesEdit.php
index 8c1c41f..f6fc3ea 100644
--- a/application/modules/dev/forms/BootmenuEntriesEdit.php
+++ b/application/modules/dev/forms/BootmenuEntriesEdit.php
@@ -82,15 +82,21 @@ class dev_Form_BootmenuEntriesEdit extends Zend_Form
));
}
+ if($_POST['kclactive'])
+ $kcllength = 175 - strlen($this->bootoslist[$_POST['bootosID']]->getDefaultkcl());
+ else
+ $kcllength = 175;
+
$this->addElement('textarea', 'kclappend', array(
'filters' => array('StringTrim'),
'validators' => array(
- array('StringLength', false, array(0, 50)),
+ array('StringLength', false, array(0, $kcllength)),
),
'required' => false,
'cols' => 50,
'rows' => 5,
- 'label' => 'KCL-Append:'
+ 'label' => 'KCL-Append:',
+ 'description' => 'Chars left: ' . $kcllength
));
diff --git a/application/modules/dev/forms/BootosCreate.php b/application/modules/dev/forms/BootosCreate.php
index 4399a62..a8731a7 100644
--- a/application/modules/dev/forms/BootosCreate.php
+++ b/application/modules/dev/forms/BootosCreate.php
@@ -76,7 +76,7 @@ class dev_Form_BootosCreate extends Zend_Form
$this->addElement('textarea', 'defaultkcl', array(
'filters' => array('StringTrim'),
'validators' => array(
- array('StringLength', false, array(0, 50)),
+ array('StringLength', false, array(0, 175)),
),
'required' => false,
'rows' => 5,
diff --git a/application/modules/dev/forms/BootosEdit.php b/application/modules/dev/forms/BootosEdit.php
index 4a0ee3b..000ec7a 100644
--- a/application/modules/dev/forms/BootosEdit.php
+++ b/application/modules/dev/forms/BootosEdit.php
@@ -84,7 +84,7 @@ class dev_Form_BootosEdit extends Zend_Form
$this->addElement('textarea', 'defaultkcl', array(
'filters' => array('StringTrim'),
'validators' => array(
- array('StringLength', false, array(0, 50)),
+ array('StringLength', false, array(0, 175)),
),
'required' => false,
'rows' => 5,