slitaz-base-files view rootfs/var/www/cgi-bin/cgi-env.sh @ rev 318

Add Japanese translations (thanks Keiichi Shiga)
author Aleksej Bobylev <al.bobylev@gmail.com>
date Tue Jan 10 12:30:48 2017 +0200 (2017-01-10)
parents 91fcb259b3bf
children
line source
1 #!/bin/sh
2 . /lib/libtaz.sh
4 # Internationalization.
5 TEXTDOMAIN='slitaz-base'
6 . /etc/locale.conf
7 export TEXTDOMAIN LANG
9 . /usr/lib/slitaz/httphelper.sh
10 header
12 title=$(_ 'CGI SHell Environment')
13 cat <<EOT
14 <!DOCTYPE html>
15 <html>
16 <head>
17 <meta charset="UTF-8">
18 <title>$title</title>
19 <link rel="stylesheet" href="../style.css">
20 </head>
21 <body>
23 <!-- Header -->
24 <div id="header">
25 <h1>$title</h1>
26 </div>
28 <!-- Content -->
29 <div id="content">
31 <p>$(_ "Welcome to the SliTaz web server CGI Shell environment. Let the \
32 power of SHell script meet the web! Here you can check HTTP info and try some \
33 requests.")</p>
35 <p>$(_ 'Including %s in your scripts lets you use PHP-like syntax such as: %s' \
36 '/usr/lib/slitaz/httphelper.sh' '$(GET var)')</p>
38 <p>$(_ 'QUERY_STRING test:')
39 <a href="$SCRIPT_NAME?var=value">$SCRIPT_NAME?var=value</a>
40 </p>
43 <h2>$(_ 'HTTP Info')</h2>
45 <pre>$(httpinfo)</pre>
48 <!-- End content -->
49 </div>
51 </body>
52 </html>
53 EOT
55 exit 0