# Generating HTML in a console application

**URL:** <https://www.ruby-forum.com/t/generating-html-in-a-console-application/134222>\
**Category:** Ruby\
**Created:** [April 9, 2008, 1:42am UTC](https://www.ruby-forum.com/t/generating-html-in-a-console-application/134222 "2008-04-09T01:42:03Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![bado](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/f1d935/32.png) [@bado](https://www.ruby-forum.com/u/bado)\
**Post date:** [April 9, 2008, 1:42am UTC](https://www.ruby-forum.com/t/generating-html-in-a-console-application/134222/1 "2008-04-09T01:42:03Z")

</div>

I’d like to generate HTML in a console application and I found  
[http://amrita.sourceforge.jp](http://amrita.sourceforge.jp)  
Can you give me other alternatives?

Thanks in advance.

---

<div class="post-metadata">

**Author:** ![bado](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/f1d935/32.png) [@bado](https://www.ruby-forum.com/u/bado)\
**Post date:** [April 9, 2008, 1:57am UTC](https://www.ruby-forum.com/t/generating-html-in-a-console-application/134222/2 "2008-04-09T01:57:15Z")

</div>

-----BEGIN PGP SIGNED MESSAGE-----  
Hash: SHA1

Ubaldo V. wrote:  
| I’d like to generate HTML in a console application and I found  
| [http://amrita.sourceforge.jp](http://amrita.sourceforge.jp)  
| Can you give me other alternatives?  
|  
| Thanks in advance.  
|  
|

RedCloth (gem install RedCloth) comes to mind.

* * *

Phillip G.  
Twitter: [twitter.com/cynicalryan](http://twitter.com/cynicalryan)

~ - You know you’ve been hacking too long when…  
…people talk to you while you’re trying to work, and you think, “mesg  
n”.  
-----BEGIN PGP SIGNATURE-----  
Version: GnuPG v1.4.8 (MingW32)  
Comment: Using GnuPG with Mozilla - [http://enigmail.mozdev.org](http://enigmail.mozdev.org)

iEYEARECAAYFAkf8BkAACgkQbtAgaoJTgL+QCgCdFjj905ouPiHfHANdfRCQ205v  
L2EAoJRs/fJHbwWDEK5SW+ey0Prfqfxj  
=sfN0  
-----END PGP SIGNATURE-----

---

<div class="post-metadata">

**Author:** ![bado](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/f1d935/32.png) [@bado](https://www.ruby-forum.com/u/bado)\
**Post date:** [April 9, 2008, 3:40am UTC](https://www.ruby-forum.com/t/generating-html-in-a-console-application/134222/3 "2008-04-09T03:40:13Z")

</div>

On Apr 8, 7:41 pm, “Ubaldo V.” [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> I’d like to generate HTML in a console application and I foundhttp://amrita.sourceforge.jp  
> Can you give me other alternatives?

What are you trying to do?

T.

---

<div class="post-metadata">

**Author:** ![bado](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/f1d935/32.png) [@bado](https://www.ruby-forum.com/u/bado)\
**Post date:** [April 9, 2008, 4:47pm UTC](https://www.ruby-forum.com/t/generating-html-in-a-console-application/134222/4 "2008-04-09T16:47:47Z")

</div>

On Tue, Apr 8, 2008 at 9:39 PM, Trans [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> 

It’s to generate a report which is basically an HTML table. I know I  
can generate the HTML using IO calls, but I just wanted to know if  
something was made for the same purpose.

---

<div class="post-metadata">

**Author:** ![bado](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/f1d935/32.png) [@bado](https://www.ruby-forum.com/u/bado)\
**Post date:** [April 9, 2008, 5:14pm UTC](https://www.ruby-forum.com/t/generating-html-in-a-console-application/134222/5 "2008-04-09T17:14:23Z")

</div>

-----BEGIN PGP SIGNED MESSAGE-----  
Hash: SHA1

Ubaldo V. wrote:

| It’s to generate a report which is basically an HTML table. I know I  
| can generate the HTML using IO calls, but I just wanted to know if  
| something was made for the same purpose.

Did you take a look at Ruby Reports?

> **[O'Reilly Media - Technology and Business Training](https://www.oreilly.com)**
>
> Gain technology and business knowledge and hone your skills with learning resources created and curated by O'Reilly's experts: live online training, video, books, our platform has content from 200+ of the world's best publishers.

* * *

Phillip G.  
Twitter: [twitter.com/cynicalryan](http://twitter.com/cynicalryan)  
-----BEGIN PGP SIGNATURE-----  
Version: GnuPG v1.4.8 (MingW32)  
Comment: Using GnuPG with Mozilla - [http://enigmail.mozdev.org](http://enigmail.mozdev.org)

iEYEARECAAYFAkf83SIACgkQbtAgaoJTgL8wYACghH8ezsHkMMifnSDAPWwU7pdt  
6nMAn0aH9dcL24TE9K2vZTl516vcMeFJ  
=O/Er  
-----END PGP SIGNATURE-----

---

<div class="post-metadata">

**Author:** ![bado](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/f1d935/32.png) [@bado](https://www.ruby-forum.com/u/bado)\
**Post date:** [April 10, 2008, 8:47am UTC](https://www.ruby-forum.com/t/generating-html-in-a-console-application/134222/6 "2008-04-10T08:47:13Z")

</div>

On 10/04/2008, at 12:46 AM, Ubaldo V. wrote:

> > T.
> 
> It’s to generate a report which is basically an HTML table. I know I  
> can generate the HTML using IO calls, but I just wanted to know if  
> something was made for the same purpose.

How about HAML?

Julian.

Learn Ruby on Rails! Check out the FREE VIDS (for a limited time)  
VIDEO #3 out NOW!  
[http://sensei.zenunit.com/](http://sensei.zenunit.com/)

---

<div class="post-metadata">

**Author:** ![bado](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/f1d935/32.png) [@bado](https://www.ruby-forum.com/u/bado)\
**Post date:** [April 9, 2008, 9:05am UTC](https://www.ruby-forum.com/t/generating-html-in-a-console-application/134222/7 "2008-04-09T09:05:49Z")

</div>

> I’d like to generate HTML in a console application  
> Can you give me other alternatives?

This may be obvious, but since you can view a html page just as a  
long string, you can generate it in plain ruby too on your own just as  
well.

One problem amrita might have compared therein is that the html data  
must pre-exist statically, and can not be generated via amrita.
