8

how to embed a bash prompt/terminal inside ruby on rails web page?

how to execute a linux command from the web page, and get the output of the ommand?

sarav
  • 111
  • 1
  • 2
  • 4
  • You are looking for an AJAX terminal. Several of them are mentioned in this [Stack overflow question](http://stackoverflow.com/questions/1944818/whats-a-good-browser-based-terminal-emulator) – Daniel Lopez Jul 29 '11 at 16:12

3 Answers3

2

You must be looking for answers in this question: Terminal on the web browser?

I myself found the right references there.

Community
  • 1
  • 1
Ikon
  • 661
  • 8
  • 14
1

Why would you do that? :))

It's simple though, since ruby has %x[]

output = %x[#{input}]
glebm
  • 20,282
  • 8
  • 51
  • 67
0

The simplest approach would probably be to take a preexisting embeddable SSH implementation, such as a Java Applet, and include that in the page.

Community
  • 1
  • 1
Quentin
  • 914,110
  • 126
  • 1,211
  • 1,335