るりまサーチ

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

別のキーワード

  1. string []=
  2. string slice!
  3. string slice
  4. string []
  5. string gsub

ライブラリ

クラス

モジュール

キーワード

検索結果

REXML::Element#text(path = nil) -> String | nil (18364.0)

先頭のテキスト子ノードの文字列を返します。

...EXML::Text#value も参照してください。

path を渡した場合は、その XPath 文字列で指定される
テキストノードの文字列を返します。

テキストノードがない場合には nil を返します。

@param path XPath文字列
@see REXML::Element#get_text

//em...
...list[][ruby]{
require 'rexml/document'
doc = REXML::Document.new "<p>some text <b>this is bold!</b> more text</p>"
# doc.root (<p> ... </p>) は2つのテキストノード("some text " と " more text"
# を持っているが、前者を返す
doc.root.text # => "some text "
//}...

CGI::HtmlExtension#text_field(name = "", value = nil, size = 40, maxlength = nil) -> String (6564.0)

タイプが text である input 要素を生成します。

...タイプが text である input 要素を生成します。

@param name name 属性の値を指定します。

@param value 属性の値を指定します。

@param size size 属性の値を指定します。

@param maxlength maxlength 属性の値を指定します。

例:
text
_field("name...
...TYPE="text" NAME="name" SIZE="40">

text
_field("name", "value")
# <INPUT TYPE="text" NAME="name" VALUE="value" SIZE="40">

text
_field("name", "value", 80)
# <INPUT TYPE="text" NAME="name" VALUE="value" SIZE="80">

text
_field("name", "value", 80, 200)
# <INPUT TYPE="text" NAME...
...="name" VALUE="value" SIZE="80" MAXLENGTH="200">...

CGI::HtmlExtension#text_field(attributes) -> String (6389.0)

タイプが text である input 要素を生成します。

...タイプが text である input 要素を生成します。

@param attributes 属性をハッシュで指定します。

text
_field({ "NAME" => "name", "VALUE" => "value" })
# <INPUT TYPE="text" NAME="name" VALUE="value">...

CGI#header(options = "text/html") -> String (358.0)

HTTP ヘッダを options に従って生成します。 CGI#out と違い、標準出力には出力しません。 CGI#out を使わずに自力で HTML を出力したい場合などに使います。 このメソッドは文字列エンコーディングを変換しません。

...を変換しません。

ヘッダのキーとしては以下が利用可能です。

: type
Content-Type ヘッダです。デフォルトは "text/html" です。
: charset
ボディのキャラクタセットを Content-Type ヘッダに追加します。
: nph
真偽値を指定します...
...ES" --> "506 Variant Also Negotiates"

@param options Hash か文字列で HTTP ヘッダを生成するための情報を指定します。

例:
header
# Content-Type: text/html

header("text/plain")
# Content-Type: text/plain

header({"nph" =>...
...=> ENV['SERVER_SOFTWARE'],
"connection" => "close",
"type" => "text/html",
"charset" => "iso-2022-jp",
# Content-Type: text/html; charset=iso-2022-jp
"language" => "ja",
"expires" => Time...

CGI#out(options = "text/html") { .... } (210.0)

HTTP ヘッダと、ブロックで与えられた文字列を標準出力に出力します。

...@param options Hash か文字列で HTTP ヘッダを生成するための情報を指定します。

例:
cgi = CGI.new
cgi.out{ "string" }
# Content-Type: text/html
# Content-Length: 6
#
# string

cgi.out("text/plain"){ "string"...
...}
# Content-Type: text/plain
# Content-Length: 6
#
# string

cgi.out({"nph" => true,
"status" => "OK", # == "200 OK"
"server" => ENV['SERVER_SOFTWARE'],
"connection" => "close",...
..."type" => "text/html",
"charset" => "iso-2022-jp",
# Content-Type: text/html; charset=iso-2022-jp
"language" => "ja",
"expires" => Time.now + (3600 * 24 * 30),
"cookie" => [cookie1, coo...

絞り込み条件を変える