私はこのエラーを12時間トラブルシューティングしていますが、これをこれに絞り込んだと思います。Internet Explorerのポストリミットは3926文字です。どうすればこれを回避できますか?
jsonオブジェクトであれ、ストリングであれ、postメソッドを提供する場合、IEは〜3926文字までを許可します。他には何も、どんな形や大きさ、その中にこれがあれば、そのがそうのように渡されているとされています。他のすべてのブラウザで
<form method="post" action="/generate_csv.csv?calc[][amount_paid]=0.0&calc[][date_awarded]=02%2F02%2F1981&calc[][date_paid]=12%2F31%2F1981&calc[][interest_rate]=12.0&calc[][principal]=1955.96&calc[][tf]=0.912328767123288&calc[][total_interest]=214.14&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F1982&calc[][date_paid]=12%2F31%2F1982&calc[][interest_rate]=12.0&calc[][principal]=1955.96&calc[][tf]=1.0&calc[][total_interest]=234.72&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F1983&calc[][date_paid]=12%2F31%2F1983&calc[][interest_rate]=12.0&calc[][principal]=1955.96&calc[][tf]=1.0&calc[][total_interest]=234.72&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F1984&calc[][date_paid]=12%2F31%2F1984&calc[][interest_rate]=12.0&calc[][principal]=1955.96&calc[][tf]=1.0027397260274&calc[][total_interest]=235.36&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F1985&calc[][date_paid]=12%2F31%2F1985&calc[][interest_rate]=12.0&calc[][principal]=1955.96&calc[][tf]=1.0&calc[][total_interest]=234.72&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F1986&calc[][date_paid]=12%2F31%2F1986&calc[][interest_rate]=9.5&calc[][principal]=1955.96&calc[][tf]=1.0&calc[][total_interest]=185.82&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F1987&calc[][date_paid]=12%2F31%2F1987&calc[][interest_rate]=7.5&calc[][principal]=1955.96&calc[][tf]=1.0&calc[][total_interest]=146.7&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F1988&calc[][date_paid]=12%2F31%2F1988&calc[][interest_rate]=6.0&calc[][principal]=1955.96&calc[][tf]=1.0027397260274&calc[][total_interest]=117.68&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F1989&calc[][date_paid]=12%2F31%2F1989&calc[][interest_rate]=7.0&calc[][principal]=1955.96&calc[][tf]=1.0&calc[][total_interest]=136.92&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F1990&calc[][date_paid]=12%2F31%2F1990&calc[][interest_rate]=8.0&calc[][principal]=1955.96&calc[][tf]=1.0&calc[][total_interest]=156.48&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F1991&calc[][date_paid]=12%2F31%2F1991&calc[][interest_rate]=8.5&calc[][principal]=1955.96&calc[][tf]=1.0&calc[][total_interest]=166.26&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F1992&calc[][date_paid]=12%2F31%2F1992&calc[][interest_rate]=7.5&calc[][principal]=1955.96&calc[][tf]=1.0027397260274&calc[][total_interest]=147.1&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F1993&calc[][date_paid]=12%2F31%2F1993&calc[][interest_rate]=5.5&calc[][principal]=1955.96&calc[][tf]=1.0&calc[][total_interest]=107.58&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F1994&calc[][date_paid]=12%2F31%2F1994&calc[][interest_rate]=3.5&calc[][principal]=1955.96&calc[][tf]=1.0&calc[][total_interest]=68.46&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F1995&calc[][date_paid]=12%2F31%2F1995&calc[][interest_rate]=3.5&calc[][principal]=1955.96&calc[][tf]=1.0&calc[][total_interest]=68.46&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F1996&calc[][date_paid]=12%2F31%2F1996&calc[][interest_rate]=5.5&calc[][principal]=1955.96&calc[][tf]=1.0027397260274&calc[][total_interest]=107.87&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F1997&calc[][date_paid]=12%2F31%2F1997&calc[][interest_rate]=5.5&calc[][principal]=1955.96&calc[][tf]=1.0&calc[][total_interest]=107.58&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F1998&calc[][date_paid]=12%2F31%2F1998&calc[][interest_rate]=5.5&calc[][principal]=1955.96&calc[][tf]=1.0&calc[][total_interest]=107.58&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F1999&calc[][date_paid]=12%2F31%2F1999&calc[][interest_rate]=5.5&calc[][principal]=1955.96&calc[][tf]=1.0&calc[][total_interest]=107.58&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F2000&calc[][date_paid]=12%2F31%2F2000&calc[][interest_rate]=5.0&calc[][principal]=1955.96&calc[][tf]=1.0027397260274&calc[][total_interest]=98.07&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F2001&calc[][date_paid]=12%2F31%2F2001&calc[][interest_rate]=5.5&calc[][principal]=1955.96&calc[][tf]=1.0&calc[][total_interest]=107.58&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F2002&calc[][date_paid]=12%2F31%2F2002&calc[][interest_rate]=6.0&calc[][principal]=1955.96&calc[][tf]=1.0&calc[][total_interest]=117.36&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F2003&calc[][date_paid]=12%2F31%2F2003&calc[][interest_rate]=3.0&calc[][principal]=1955.96&calc[][tf]=1.0&calc[][total_interest]=58.68&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F2004&calc[][date_paid]=12%2F31%2F2004&calc[][interest_rate]=2.0&calc[][principal]=1955.96&calc[][tf]=1.0027397260274&calc[][total_interest]=39.23&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F2005&calc[][date_paid]=12%2F31%2F2005&calc[][interest_rate]=1.0&calc[][principal]=1955.96&calc[][tf]=1.0&calc[][total_interest]=19.56&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F2006&calc[][date_paid]=12%2F31%2F2006&calc[][interest_rate]=2.0&calc[][principal]=1955.96&calc[][tf]=1.0&calc[][total_interest]=39.12&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F2007&calc[][date_paid]=12%2F31%2F2007&calc[][interest_rate]=4.0&calc[][principal]=1955.96&calc[][tf]=1.0&calc[][total_interest]=78.24&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F2008&calc[][date_paid]=12%2F31%2F2008&calc[][interest_rate]=5.5&calc[][principal]=1955.96&calc[][tf]=1.0027397260274&calc[][total_interest]=107.87&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F2009&calc[][date_paid]=12%2F31%2F2009&calc[][interest_rate]=4.0&calc[][principal]=1955.96&calc[][tf]=1.0&calc[][total_interest]=78.24&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F2010&calc[][date_paid]=12%2F31%2F2010&calc[][interest_rate]=1.5&calc[][principal]=1955.96&calc[][tf]=1.0&calc[][total_interest]=29.34&calc[][amount_paid]=0.0&calc[][date_awarded]=1%2F1%2F2011&calc[][date_paid]=02%2F09%2F2011&calc[][interest_rate]=0.5&calc[][principal]=1955.96&calc[][tf]=0.10958904109589&calc[][total_interest]=1.07" accept-charset="UTF-8"><div style="margin: 0pt; padding: 0pt; display: inline;"><input type="hidden" value="✓" name="utf8"><input type="hidden" value="dbxrVZT2J42AB0QdMFi2XPggVGAQKtm8IkcuIj+U2jU=" name="authenticity_token"></div>
、これはでも問題は全くを渡しません。しかし、IEはこれをある時点で許容しません。
誰でも私は小さくて凝縮された方法で、あるいは別の方法で同じ量のデータを渡すことができますか?
代わりに、私は考えていたオブジェクトのエイリアスを渡すことができるので、オブジェクト自体がコントローラ間で渡されるが、ではなく、ビューを通して。これは、オブジェクトをデータベースに保存することなく行われます。ここで大声で考えてみてください。
任意のアイデアを開くことができます。 :D
マイHAML:
= form_tag generate_csv_path(:calc => @calc.results, :total_interest => @calc.total_interest, :per_diem => @calc.per_diem, :docket_num => @calc.docket_num, :our_file_num => @calc.our_file_num) do
= submit_tag 'Print CSV', :id => "print_csv"
UPDATE
だから私は小さな隠しフィールドにそれらを破るしようとしているすべての項目をループだし、彼らはすべてのハッシュとして出て来ています
- @calc.results.each do |k, v|
= hidden_field :calc_result, "#{k[:total_interest]}"
が生成されます
"117.68"=>"",
"166.26"=>"",
"147.1"=>"",
"107.58"=>"",
"58.68"=>"",
それほど信じられない奇妙な..私は最終的にハッシュ値を作成できるかもしれないと思った。したがって、1つのcalc_resultが5つの異なる属性を持つことができます。
なぜあなたはURLに投稿していますか?代わりにこれらのフォームフィールドを非表示にしてはいけませんか? –
IEのURLの長さはポストの長さではないと思う。 –
@ダニエル - これを実行するためにデータベースを使用していないため、私は快適ゾーンから外れています。あなたはhidden_fieldsでこのフォーム投稿をどのように持っていますか?私は私のハムが言っていることについて上記で更新します。 – Trip