tazpanel view help.cgi @ rev 338
settings.cgi: set tz
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Wed Jan 02 14:12:12 2013 +0100 (2013-01-02) |
parents | 72e9955ebdff |
children | b3f5245b1e90 |
line source
1 #!/bin/sh
2 #
3 # help.cgi - Display TazPanel doc and README.
4 #
5 # Copyright (C) 2011 SliTaz GNU/Linux - BSD License
6 #
8 # Common functions from libtazpanel
9 . lib/libtazpanel
10 get_config
11 header
13 # ENTER will search but user may search for a button, so put one.
14 search_form() {
15 cat << EOT
16 <div class="search">
17 <form method="get" action="$SCRIPT_NAME">
18 <p>
19 <input type="text" name="manual" size="20">
20 <input type="submit" class="radius" value="$(gettext 'Manual')">
21 </p>
22 </form>
23 </div>
24 EOT
25 }
27 # Cat translated help content
28 TITLE=$(gettext 'TazPanel - Help & Doc')
30 xhtml_header
31 search_form
33 if [ "$(GET manual)" ]; then
34 echo '<pre>'
35 man $(GET manual)
36 echo '</pre>'
37 else
38 if [ -d doc ]; then
39 cat doc/tazpanel.html
40 else
41 cat /usr/share/doc/tazpanel/tazpanel.html
42 fi
44 # cat << EOT
45 #<h3>README</h3>
46 #<pre>$(cat $PANEL/README)</pre>
47 #EOT
48 cat $PANEL/README.html
50 fi
52 xhtml_footer
53 exit 0