mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* lib/cgi/html.rb (CGI::HtmlExtension::popup_menu):
fix the calls #bytesize on array parameters. [ruby-core:18919] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@19614 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
5958f6af19
commit
c0f84528c7
2 changed files with 8 additions and 3 deletions
|
@ -1,3 +1,8 @@
|
|||
Sun Sep 28 23:08:38 2008 Takeyuki Fujioka <xibbar@ruby-lang.org>
|
||||
|
||||
* lib/cgi/html.rb (CGI::HtmlExtension::popup_menu):
|
||||
fix the calls #bytesize on array parameters. [ruby-core:18919]
|
||||
|
||||
Sun Sep 28 22:44:26 2008 Takeyuki Fujioka <xibbar@ruby-lang.org>
|
||||
|
||||
* lib/cgi/core.rb (CGI::parse): ignore illegal query params.
|
||||
|
|
|
@ -624,13 +624,13 @@ class CGI
|
|||
if value.kind_of?(String)
|
||||
option({ "VALUE" => value }){ value }
|
||||
else
|
||||
if value[value.bytesize - 1] == true
|
||||
if value[value.size - 1] == true
|
||||
option({ "VALUE" => value[0], "SELECTED" => true }){
|
||||
value[value.bytesize - 2]
|
||||
value[value.size - 2]
|
||||
}
|
||||
else
|
||||
option({ "VALUE" => value[0] }){
|
||||
value[value.bytesize - 1]
|
||||
value[value.size - 1]
|
||||
}
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue