X-Git-Url: http://git.cyclocoop.org//%27http:/code.google.com/p/ie7-js//%27?a=blobdiff_plain;f=includes%2FFormOptions.php;h=725a512980937c3b51c1c400711165e797526ce6;hb=69ae945e8d39972a07bea89ddb64bc0189b43ac2;hp=6706db7e53318799fad016ba07e5b3ae6142c0ac;hpb=202f695f671bb1b6c25ebec219da348e9935692e;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/FormOptions.php b/includes/FormOptions.php index 6706db7e53..725a512980 100644 --- a/includes/FormOptions.php +++ b/includes/FormOptions.php @@ -52,6 +52,9 @@ class FormOptions implements ArrayAccess { * This is useful for the namespace selector. */ const INTNULL = 3; + /** Array type, maps guessType() to WebRequest::getArray() + * @since 1.29 */ + const ARR = 5; /* @} */ /** @@ -120,6 +123,8 @@ class FormOptions implements ArrayAccess { return self::FLOAT; } elseif ( is_string( $data ) ) { return self::STRING; + } elseif ( is_array( $data ) ) { + return self::ARR; } else { throw new MWException( 'Unsupported datatype' ); } @@ -358,6 +363,9 @@ class FormOptions implements ArrayAccess { case self::INTNULL: $value = $r->getIntOrNull( $name ); break; + case self::ARR: + $value = $r->getArray( $name ); + break; default: throw new MWException( 'Unsupported datatype' ); }