From 59f1829e602454ea548710f61618a034fa31b30e Mon Sep 17 00:00:00 2001 From: Roland Gruber Date: Wed, 30 May 2012 19:00:25 +0000 Subject: [PATCH] transient checkboxes --- lam/lib/html.inc | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/lam/lib/html.inc b/lam/lib/html.inc index 61641781..cdc3d6a5 100644 --- a/lam/lib/html.inc +++ b/lam/lib/html.inc @@ -1387,6 +1387,9 @@ class htmlInputCheckbox extends htmlElement { protected $tableRowsToHide = array(); /** list of enclosing table rows to show when checked */ protected $tableRowsToShow = array(); + /** indicates that this field should not automatically be saved in the self service or server profile */ + private $transient = false; + /** * Constructor. @@ -1472,6 +1475,9 @@ class htmlInputCheckbox extends htmlElement { } echo ''; echo $script; + if ($this->transient) { + return array(); + } return array($this->name => 'checkbox'); } @@ -1514,6 +1520,14 @@ class htmlInputCheckbox extends htmlElement { $this->tableRowsToShow = $tableRowsToShow; } + /** + * Specifies that the value should not be automatically saved when used in self service or server profile (default: false). + * + * @param boolean $transient transient field + */ + public function setTransient($transient) { + $this->transient = $transient; + } }