summaryrefslogtreecommitdiffstats
path: root/frontends/php/include/classes/cform.inc.php
diff options
context:
space:
mode:
authorosmiy <osmiy@97f52cf1-0a1b-0410-bd0e-c28be96e8082>2006-01-13 15:51:21 +0000
committerosmiy <osmiy@97f52cf1-0a1b-0410-bd0e-c28be96e8082>2006-01-13 15:51:21 +0000
commite9057de8be3f2273d6251b7d0a6095cf978f27f1 (patch)
treed629cc30cf6b96e12032846be3b08add7b0a8237 /frontends/php/include/classes/cform.inc.php
parent2934d33bae581c7c54502ce02364f10c3b7d7a45 (diff)
downloadzabbix-e9057de8be3f2273d6251b7d0a6095cf978f27f1.tar.gz
zabbix-e9057de8be3f2273d6251b7d0a6095cf978f27f1.tar.xz
zabbix-e9057de8be3f2273d6251b7d0a6095cf978f27f1.zip
- Frontend improvements. (Eugene)
git-svn-id: svn://svn.zabbix.com/trunk@2523 97f52cf1-0a1b-0410-bd0e-c28be96e8082
Diffstat (limited to 'frontends/php/include/classes/cform.inc.php')
-rw-r--r--frontends/php/include/classes/cform.inc.php12
1 files changed, 11 insertions, 1 deletions
diff --git a/frontends/php/include/classes/cform.inc.php b/frontends/php/include/classes/cform.inc.php
index 065185f9..3dee3109 100644
--- a/frontends/php/include/classes/cform.inc.php
+++ b/frontends/php/include/classes/cform.inc.php
@@ -22,11 +22,12 @@
class CForm extends CTag
{
/* public */
- function CForm($action=NULL, $method='get')
+ function CForm($action=NULL, $method='get', $enctype=NULL)
{
parent::CTag("form","yes");
$this->SetMethod($method);
$this->SetAction($action);
+ $this->SetEnctype($enctype);
}
function SetMethod($value='post')
{
@@ -46,6 +47,15 @@
}
return $this->AddOption("action",$value);
}
+ function SetEnctype($value=NULL)
+ {
+ if(is_null($value)){
+ return $this->DelOption("enctype");
+ }elseif(!is_string($value)){
+ return $this->error("Incorrect value for SetEnctype [$value]");
+ }
+ return $this->AddOption("enctype",$value);
+ }
function AddVar($name, $value)
{
$this->AddItem(new CVar($name, $value));