[#38470] ruby-dev summary 21403-21530 (draft) — Minero Aoki <aamine@...>

青木です。

25 messages 2003/10/07
[#38475] Re: ruby-dev summary 21403-21530 (draft) — maili31s@... (SugHimsi==SUGIHARA Hiroshi) 2003/10/07

すぎむし。

[#38480] Re: ruby-dev summary 21403-21530 (draft) — Minero Aoki <aamine@...> 2003/10/08

青木です。

[#38481] marshal_dump (was Re: ) — m_seki@... 2003/10/08

[#38484] Re: marshal_dump (was Re: ) — matz@... (Yukihiro Matsumoto) 2003/10/09

まつもと ゆきひろです

[#38486] Re: marshal_dump (was Re: ) — Masatoshi Seki <m_seki@...> 2003/10/09

咳といいます

[#38489] exit status on exit! — YANAGAWA Kazuhisa <kjana@...4lab.to>

<http://www.unixuser.org/~ysjj/diary/?200310a&to=200310082#200310082>

29 messages 2003/10/09
[#38490] Re: exit status on exit! — Koji Arai <JCA02266@...> 2003/10/09

新井です。

[#38503] Re: exit status on exit! — YANAGAWA Kazuhisa <kjana@...4lab.to> 2003/10/10

In Message-Id: <20031010.082218.74733862.JCA02266@nifty.ne.jp>

[#38505] Re: exit status on exit! — Koji Arai <JCA02266@...> 2003/10/10

新井です。

[#38507] Re: exit status on exit! — matz@... (Yukihiro Matsumoto) 2003/10/11

まつもと ゆきひろです

[#38514] Re: exit status on exit! — YANAGAWA Kazuhisa <kjana@...4lab.to> 2003/10/11

In Message-Id: <1065883639.405037.23137.nullmailer@picachu.netlab.jp>

[#38515] Re: exit status on exit! — WATANABE Hirofumi <eban@...> 2003/10/11

わたなべです。

[ruby-list:38502] Re: Amrita と mod_rubyの相性は ?

From: 山本 達也 <rcn@...>
Date: 2003-10-10 14:10:20 UTC
List: ruby-list #38502
山本(rcn)@ntt〜kddi です。こんにちは。

> 澤井@一個人 です.

> では Amrita に文字列を出力してもらえば いいの
> ではないでしょうか?
> ----------------------------------------
> #!/usr/local/bin/ruby
> require "cgi"
> require "amrita/template"
> include Amrita
>  
> cgi = CGI.new
> cgi.header("type" => "text/html")
> 
> tmpl = TemplateFile.new("template.html")
> data = {
>         :title => "hello world",
>         :body => "Amrita is a html template libraly for Ruby"
> }
> response_body = ""
> tmpl.expand(response_body, data)
> cgi.out({"content-type" => "text/html"}){response_body}
> ----------------------------------------

 なるほど。こういう書き方ができるのですね。
・・・こんな初歩的なことも知りませんでした。

 うまく動きました。どうもありがとうございました。
どうも C の STDOUT のイメージでいたので・・・
頭が硬化しているなぁ。


----
山本 達也 <rcn@gol.com> http://r.oyt.jp/ http://diary.oyt.jp/



In This Thread