/[SysIface]/templates/example/welcome.html.epl
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Contents of /templates/example/welcome.html.epl

Parent Directory Parent Directory | Revision Log Revision Log


Revision 4 - (show annotations)
Tue Jun 16 19:47:21 2009 UTC (9 years, 9 months ago) by dpavlin
File size: 692 byte(s)
execute commands on remote hostname

1 % my $self = shift;
2 <h2><%= $self->stash('message') %></h2>
3 This page was generated from the template
4 "templates/example/welcome.html.epl" and the layout
5 "templates/layouts/default.html.epl",
6 <a href="<%= $self->url_for %>">click here</a>
7 to reload the page or
8 <a href="/index.html">here</a>
9 to move forward to a static page.
10
11 % my $hostname = $self->param('hostname');
12
13 <form method=get>
14 <label for=hostname>hostname
15 <input name=hostname type=text value="<%= $hostname %>">
16 </label>
17 <input type=submit value=run>
18 </form>
19
20 % foreach my $cmd ( @{ $self->stash('commands') } ) {
21 % my $run = $hostname ? "ssh $hostname $cmd" : $cmd;
22 <b><tt><%= $cmd %></tt></b><br>
23 <pre><%= `$run` %></pre>
24 % }

  ViewVC Help
Powered by ViewVC 1.1.26