■テキストフィールドの内容を加算する
		■書式
			
			require "cgi"
			オブジェクト = CGI.new
			変数1 = オブジェクト[テキストフィールド名][位置]
			変数2 = オブジェクト[テキストフィールド名][位置]
			変数3 = 変数1.to_f + 変数2.to_f
			■説明
			
			テキストフィールドの内容を加算するにはcgiライブラリを利用しフィールド内のデータを読み出します。このまま、加算すると文字列同士の連結になってしまい、計算結果を得る事が出来ません。そこでto_iやto_fで数値型に変換してから加算します。結果はprintで表示します。
		
			■サンプル (CGI)
			
			#!/usr/bin/ruby
			require "cgi"
			formData = CGI.new
			n1 = formData["val1"][0]
			n2 = formData["val2"][0]
			result = n1.to_f + n2.to_f
			
			print "Content-type: text/html\n\n"
			print result
		
			■サンプル (HTML)
			
			<html>
			<head>
			<title>Ruby CGI Sample</title>
			</head>
			<body>
			<form method="post" action="./sample.cgi">
			値1<input type="text" name="val1"><br>
			値2<input type="text" name="val2"><br>
			<input type="submit" value="合計を出す">
			</form>
			</body>
			</html>