るりまサーチ

最速Rubyリファレンスマニュアル検索!
36件ヒット [1-36件を表示] (0.093秒)

別のキーワード

  1. _builtin file?
  2. _builtin file
  3. file truncate
  4. file atime
  5. file size

ライブラリ

クラス

検索結果

WEBrick::HTTPRequest#query -> Hash (18120.0)

リクエストのクエリーあるいはクライアントがフォームへ入力した値を表すハッシュを返します。

...巨大な文字列が
生成されてしまいます。

例:

h = req.query
p h['q'] #=> "ruby rails session"
p h['upfile']['content-type'] #=> "plain/text"
p h['upfile'].filename #=> "my_file.txt"
p h['upfile'] #=> "hoge hoge hoge"...

Net::HTTP#post(path, data, header = nil, dest = nil) -> Net::HTTPResponse (49.0)

サーバ上の path にあるエンティティに対し文字列 data を POST で送ります。

...ist[例][ruby]{
# net/http version 1.1
response, body = http.post('/cgi-bin/search.rb', 'query=subject&target=ruby')

# version 1.2
response = http.post('/cgi-bin/search.rb', 'query=subject&target=ruby')

# using block
File
.open('save.html', 'w') {|f|
http.post('/cgi-bin/search.rb', 'query=subject...

Net::HTTP#post(path, data, header = nil, dest = nil) {|body_segment| .... } -> Net::HTTPResponse (49.0)

サーバ上の path にあるエンティティに対し文字列 data を POST で送ります。

...ist[例][ruby]{
# net/http version 1.1
response, body = http.post('/cgi-bin/search.rb', 'query=subject&target=ruby')

# version 1.2
response = http.post('/cgi-bin/search.rb', 'query=subject&target=ruby')

# using block
File
.open('save.html', 'w') {|f|
http.post('/cgi-bin/search.rb', 'query=subject...